/*
Theme Name: JankoCheckedIn
Theme URI: https://jankocheckedin.com
Author: Janko Zehe
Author URI: https://jankocheckedin.com
Description: The JankoCheckedIn.com theme — Navy & Flag Red, personal-brand wordmark, pin-with-checkmark mark, and a Janko Checked In Score tableau built for structured Accor hotel reviews. Built to the JankoCheckedIn v6 brand kit. Requires the companion "JankoCheckedIn Reviews" plugin for the Hotel-Reviews post type and data.
Version: 1.2.0
Requires at least: 6.2
Requires PHP: 7.4
Tested up to: 6.6
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: jankocheckedin
*/

/* ==========================================================================
   1. Custom properties (brand tokens — v6: Navy & Flag Red)
   ========================================================================== */

:root {
	--jci-navy: #12233F;
	--jci-navy-deep: #0B1729;
	--jci-red: #B81C36;
	--jci-red-on-navy: #F0637A;
	--jci-cream: #F7F2E7;
	--jci-white: #FFFFFF;
	--jci-ink: #20242C;
	--jci-muted: #6b6455;
	--jci-muted-light: #8a8371;
	--jci-muted-navy: #AEB8CB;
	--jci-border: #E8E0CD;
	--jci-border-light: #EFE9D8;
	--jci-star-empty: #D8CCA8;

	--jci-font-serif: "Playfair Display", Georgia, "Times New Roman", serif;
	--jci-font-sans: "Work Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
	--jci-font-hand: "Caveat", "Segoe Script", cursive;

	--jci-container-width: 1160px;
	--jci-radius: 10px;
}

/* ==========================================================================
   2. Reset & base
   ========================================================================== */

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
	margin: 0;
	background: var(--jci-cream);
	color: var(--jci-ink);
	font-family: var(--jci-font-sans);
	font-size: 16px;
	line-height: 1.6;
	-webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }

a { color: var(--jci-red); text-decoration: none; }
a:hover { color: var(--jci-navy); }

h1, h2, h3, h4 {
	font-family: var(--jci-font-serif);
	color: var(--jci-navy);
	line-height: 1.2;
	margin: 0 0 0.5em;
}

ul { margin: 0; padding: 0; list-style: none; }

button { font-family: inherit; cursor: pointer; }

.jci-container {
	max-width: var(--jci-container-width);
	margin-left: auto;
	margin-right: auto;
	padding-left: 24px;
	padding-right: 24px;
}

.screen-reader-text {
	position: absolute !important;
	clip: rect(1px, 1px, 1px, 1px);
	width: 1px; height: 1px;
	overflow: hidden;
}

.jci-skip-link {
	position: absolute;
	left: -9999px;
	top: 0;
	background: var(--jci-navy);
	color: #fff;
	padding: 12px 20px;
	z-index: 10000;
}
.jci-skip-link:focus { left: 0; }

/* ==========================================================================
   3. Buttons
   ========================================================================== */

.jci-button {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	padding: 13px 26px;
	border-radius: 999px;
	font-weight: 600;
	font-size: 14px;
	letter-spacing: 0.02em;
	transition: transform 0.15s ease, background 0.15s ease, color 0.15s ease;
}
.jci-button--accent {
	background: var(--jci-red);
	color: #fff;
}
.jci-button--accent:hover {
	background: var(--jci-navy);
	color: #fff;
	transform: translateY(-1px);
}
.jci-button--outline {
	background: transparent;
	color: var(--jci-navy);
	box-shadow: inset 0 0 0 1.5px var(--jci-navy);
}
.jci-button--outline:hover {
	background: var(--jci-navy);
	color: #fff;
}

/* ==========================================================================
   4. Wordmark (used in header + footer + score tableau)
   ========================================================================== */

.jci-wordmark {
	display: inline-flex;
	align-items: center;
	gap: 12px;
}
.jci-wordmark-text {
	display: flex;
	flex-direction: column;
	line-height: 1;
}
.jci-wordmark-name {
	font-family: var(--jci-font-sans);
	font-weight: 800;
	letter-spacing: -0.01em;
}
.jci-wordmark-sub {
	font-family: var(--jci-font-sans);
	font-weight: 700;
	letter-spacing: 0.24em;
	margin-top: 6px;
}
.jci-wordmark--small .jci-wordmark-sub { margin-top: 3px; }
.jci-pin-mark { flex-shrink: 0; }

/* ==========================================================================
   5. Header & navigation
   ========================================================================== */

.jci-site-header {
	background: var(--jci-cream);
	border-bottom: 1px solid var(--jci-border);
	position: sticky;
	top: 0;
	z-index: 100;
}

.jci-site-header-inner {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding-top: 16px;
	padding-bottom: 16px;
}

.jci-brand { display: inline-flex; }

.jci-primary-menu {
	display: flex;
	align-items: center;
	gap: 32px;
}
.jci-primary-menu a {
	color: var(--jci-navy);
	font-weight: 600;
	font-size: 15px;
}
.jci-primary-menu a:hover { color: var(--jci-red); }

.jci-nav-toggle {
	display: none;
	flex-direction: column;
	justify-content: center;
	gap: 5px;
	width: 40px;
	height: 40px;
	background: transparent;
	border: none;
	padding: 0;
}
.jci-nav-toggle-bar {
	display: block;
	width: 24px;
	height: 2px;
	background: var(--jci-navy);
	transition: transform 0.2s ease, opacity 0.2s ease;
}

@media (max-width: 782px) {
	.jci-nav-toggle { display: flex; }
	.jci-primary-nav {
		display: none;
		position: absolute;
		left: 0;
		right: 0;
		top: 100%;
		background: var(--jci-cream);
		border-bottom: 1px solid var(--jci-border);
		padding: 8px 24px 24px;
	}
	.jci-primary-nav.is-open { display: block; }
	.jci-primary-menu { flex-direction: column; align-items: flex-start; gap: 18px; }
}

/* ==========================================================================
   6. Hero (front page)
   ========================================================================== */

.jci-hero {
	background: var(--jci-navy);
	padding: 96px 0 88px;
	text-align: center;
}
.jci-hero-inner { max-width: 760px; }
.jci-hero-kicker {
	color: var(--jci-red-on-navy);
	text-transform: uppercase;
	letter-spacing: 0.18em;
	font-size: 12px;
	font-weight: 700;
	margin: 0 0 18px;
}
.jci-hero-headline {
	color: #fff;
	font-size: clamp(28px, 4vw, 44px);
	margin-bottom: 20px;
}
.jci-hero-sub {
	color: var(--jci-muted-navy);
	font-size: 17px;
	line-height: 1.7;
	margin-bottom: 32px;
}

/* ==========================================================================
   7. Section heading + review grid
   ========================================================================== */

.jci-latest-reviews { padding: 72px 0; }

.jci-section-heading {
	display: flex;
	align-items: baseline;
	justify-content: space-between;
	margin-bottom: 32px;
}
.jci-section-heading h2 { margin: 0; font-size: 28px; }
.jci-section-heading-link {
	font-weight: 600;
	font-size: 14px;
	white-space: nowrap;
}

.jci-review-grid {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 28px;
}
@media (max-width: 900px) { .jci-review-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 600px) { .jci-review-grid { grid-template-columns: 1fr; } }

.jci-review-card {
	display: flex;
	flex-direction: column;
	background: #fff;
	border-radius: var(--jci-radius);
	overflow: hidden;
	box-shadow: 0 1px 3px rgba(18, 35, 63, 0.1);
	transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.jci-review-card:hover {
	transform: translateY(-3px);
	box-shadow: 0 10px 24px rgba(18, 35, 63, 0.14);
}
.jci-review-card-media {
	position: relative;
	aspect-ratio: 16 / 11;
	background: var(--jci-navy);
	overflow: hidden;
}
.jci-review-card-media img { width: 100%; height: 100%; object-fit: cover; }
.jci-review-card-media-placeholder {
	width: 100%; height: 100%;
	display: flex; align-items: center; justify-content: center;
}
.jci-review-card-score {
	position: absolute;
	top: 14px; right: 14px;
	background: var(--jci-navy);
	color: var(--jci-red-on-navy);
	font-family: var(--jci-font-sans);
	font-weight: 800;
	font-size: 15px;
	padding: 6px 11px;
	border-radius: 999px;
}
.jci-review-card-body { padding: 20px 22px 24px; flex: 1; display: flex; flex-direction: column; }
.jci-review-card-brand {
	color: var(--jci-red);
	font-weight: 700;
	font-size: 12px;
	letter-spacing: 0.06em;
	text-transform: uppercase;
	margin-bottom: 8px;
}
.jci-review-card-title { font-size: 20px; margin-bottom: 4px; color: var(--jci-navy); }
.jci-review-card-destination { color: var(--jci-muted); font-size: 13px; }
.jci-review-card-excerpt { color: var(--jci-muted); font-size: 14px; margin-top: 10px; margin-bottom: 0; }

.jci-empty-state { color: var(--jci-muted); font-size: 15px; }

/* ==========================================================================
   8. Archive header + filters
   ========================================================================== */

.jci-archive-header { padding: 64px 0 24px; text-align: center; }
.jci-archive-header h1 { font-size: clamp(26px, 3.6vw, 38px); max-width: 720px; margin-left: auto; margin-right: auto; }
.jci-archive-description { color: var(--jci-muted); max-width: 640px; margin: 12px auto 0; }

.jci-archive-filters { padding-bottom: 32px; }
.jci-filter-row { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; }
.jci-filter-pill {
	display: inline-block;
	padding: 8px 16px;
	border-radius: 999px;
	background: #fff;
	color: var(--jci-navy);
	font-size: 13px;
	font-weight: 600;
	box-shadow: inset 0 0 0 1px var(--jci-border);
}
.jci-filter-pill:hover { box-shadow: inset 0 0 0 1.5px var(--jci-red); color: var(--jci-red); }
.jci-filter-pill.is-active { background: var(--jci-navy); color: #fff; box-shadow: none; }

.jci-review-grid-wrap { padding-bottom: 80px; }

.jci-pagination { display: flex; gap: 10px; justify-content: center; margin-top: 48px; }
.jci-pagination .page-numbers {
	display: inline-flex; align-items: center; justify-content: center;
	min-width: 38px; height: 38px; padding: 0 10px;
	border-radius: 999px; background: #fff; color: var(--jci-navy);
	font-weight: 600; font-size: 14px;
	box-shadow: inset 0 0 0 1px var(--jci-border);
}
.jci-pagination .page-numbers.current { background: var(--jci-navy); color: #fff; }

/* ==========================================================================
   9. Photo gallery + lightbox
   ========================================================================== */

.jci-gallery { padding: 40px 0 8px; }

.jci-gallery-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
	gap: 14px;
}

.jci-gallery-item {
	padding: 0;
	margin: 0;
	border: none;
	background: none;
	cursor: pointer;
	display: block;
	width: 100%;
	aspect-ratio: 4 / 3;
	border-radius: 8px;
	overflow: hidden;
}

.jci-gallery-thumb {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
	transition: transform 0.2s ease;
}

.jci-gallery-item:hover .jci-gallery-thumb { transform: scale(1.05); }

.jci-lightbox {
	position: fixed;
	inset: 0;
	background: rgba(11, 23, 41, 0.95);
	z-index: 1000;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 60px;
}
.jci-lightbox[hidden] { display: none; }

.jci-lightbox-image {
	max-width: 100%;
	max-height: 100%;
	border-radius: 6px;
	box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4);
}

.jci-lightbox-close,
.jci-lightbox-prev,
.jci-lightbox-next {
	position: absolute;
	width: 44px;
	height: 44px;
	border-radius: 50%;
	border: none;
	background: rgba(255, 255, 255, 0.12);
	color: #fff;
	font-size: 22px;
	line-height: 1;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: background 0.15s ease;
}
.jci-lightbox-close:hover,
.jci-lightbox-prev:hover,
.jci-lightbox-next:hover { background: var(--jci-red); }

.jci-lightbox-close { top: 24px; right: 24px; }
.jci-lightbox-prev { left: 24px; top: 50%; transform: translateY(-50%); }
.jci-lightbox-next { right: 24px; top: 50%; transform: translateY(-50%); }

body.jci-lightbox-open { overflow: hidden; }

@media (max-width: 600px) {
	.jci-lightbox { padding: 20px; }
	.jci-lightbox-prev, .jci-lightbox-next { width: 36px; height: 36px; font-size: 18px; }
	.jci-lightbox-close { top: 12px; right: 12px; }
	.jci-lightbox-prev { left: 12px; }
	.jci-lightbox-next { right: 12px; }
}

/* ==========================================================================
   10. Single review
   ========================================================================== */

.jci-review-hero {
	background-color: var(--jci-navy);
	background-size: cover;
	background-position: center;
	padding: 90px 0 56px;
}
.jci-review-hero-meta {
	color: var(--jci-red-on-navy);
	text-transform: uppercase;
	letter-spacing: 0.1em;
	font-size: 12px;
	font-weight: 700;
	margin: 0 0 14px;
}
.jci-review-hero-title { color: #fff; font-size: clamp(30px, 4.4vw, 48px); max-width: 900px; margin: 0; }

.jci-quick-facts {
	display: flex;
	flex-wrap: wrap;
	gap: 0;
	background: #fff;
	border-radius: var(--jci-radius);
	box-shadow: 0 1px 3px rgba(18, 35, 63, 0.1);
	margin-top: -32px;
	position: relative;
	z-index: 2;
	overflow: hidden;
}
.jci-quick-facts li {
	flex: 1 1 160px;
	padding: 18px 22px;
	border-right: 1px solid var(--jci-border-light);
	display: flex;
	flex-direction: column;
	gap: 4px;
}
.jci-quick-facts li:last-child { border-right: none; }
.jci-quick-facts-label { font-size: 11px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--jci-muted-light); }
.jci-quick-facts-value { font-weight: 600; color: var(--jci-navy); font-size: 14px; }

.jci-review-layout {
	display: grid;
	grid-template-columns: minmax(0, 1fr) 340px;
	gap: 56px;
	padding: 56px 0 80px;
	align-items: start;
}
@media (max-width: 900px) {
	.jci-review-layout { grid-template-columns: 1fr; }
	.jci-review-sidebar { order: -1; }
}

.jci-review-sidebar-sticky { position: sticky; top: 100px; }

.jci-review-video { margin-bottom: 32px; }
.jci-review-video iframe, .jci-review-video embed { width: 100%; aspect-ratio: 16/9; height: auto; border-radius: var(--jci-radius); }

/* Prose inside the main review write-up (the_content) */
.jci-review-content, .jci-page .jci-review-content {
	font-size: 17px;
	line-height: 1.75;
	color: var(--jci-ink);
}
.jci-review-content h2 {
	font-size: 26px;
	margin-top: 2.2em;
	padding-bottom: 0.4em;
	border-bottom: 2px solid var(--jci-border);
}
.jci-review-content h2:first-child { margin-top: 0; }
.jci-review-content h3 { font-size: 20px; margin-top: 1.6em; }
.jci-review-content p { margin: 0 0 1.3em; }
.jci-review-content ul, .jci-review-content ol { margin: 0 0 1.3em 1.4em; list-style: revert; }
.jci-review-content li { margin-bottom: 0.4em; }
.jci-review-content img { border-radius: var(--jci-radius); margin: 1.6em 0; }
.jci-review-content figcaption { color: var(--jci-muted); font-size: 13px; margin-top: 8px; }
.jci-review-content blockquote {
	font-family: var(--jci-font-hand);
	font-size: 26px;
	color: var(--jci-red);
	border-left: none;
	margin: 1.8em 0;
	padding: 0 0 0 28px;
	position: relative;
}
.jci-review-content a { text-decoration: underline; text-decoration-color: var(--jci-border); text-underline-offset: 3px; }

.jci-review-short-video-link { margin: 8px 0 0; }

.jci-verdict-card {
	margin-top: 48px;
	background: #fff;
	border-radius: var(--jci-radius);
	padding: 32px 36px;
	box-shadow: 0 1px 3px rgba(18, 35, 63, 0.08);
}
.jci-verdict-card h2 { margin-top: 0; font-size: 22px; }
.jci-verdict-grid {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 24px;
	margin-bottom: 18px;
}
@media (max-width: 560px) { .jci-verdict-grid { grid-template-columns: 1fr; } }
.jci-verdict-grid h3 { font-size: 14px; text-transform: uppercase; letter-spacing: 0.05em; color: var(--jci-muted); font-family: var(--jci-font-sans); }
.jci-verdict-grid p { margin: 0; color: var(--jci-ink); }
.jci-verdict-return { border-top: 1px solid var(--jci-border-light); padding-top: 16px; margin: 0; }

/* ==========================================================================
   11. JCI Score tableau
   ========================================================================== */

.jci-score-tableau {
	background: #fff;
	border-radius: var(--jci-radius);
	overflow: hidden;
	box-shadow: 0 1px 3px rgba(18, 35, 63, 0.12);
}
.jci-score-tableau-header {
	background: var(--jci-navy);
	padding: 28px 30px 24px;
	display: flex;
	flex-direction: column;
	gap: 14px;
}
.jci-score-tableau-kicker {
	display: flex;
	align-items: center;
	gap: 10px;
	text-transform: uppercase;
	letter-spacing: 0.12em;
	font-size: 11px;
	font-weight: 700;
	color: var(--jci-red-on-navy);
}
.jci-score-tableau-title { color: #fff; font-size: 21px; margin: 0; line-height: 1.25; }
.jci-score-tableau-average { display: flex; align-items: baseline; gap: 12px; }
.jci-score-tableau-number { font-family: var(--jci-font-sans); font-weight: 800; font-size: 46px; color: var(--jci-red-on-navy); line-height: 1; }
.jci-score-tableau-average-stars { display: flex; flex-direction: column; gap: 5px; }
.jci-score-tableau-outof { font-size: 11px; color: var(--jci-muted-navy); }
.jci-stars { display: inline-flex; gap: 3px; }

.jci-score-tableau-rows { padding: 6px 30px 26px; display: flex; flex-direction: column; }
.jci-score-tableau-row {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 13px 0;
	border-bottom: 1px solid var(--jci-border-light);
	font-size: 14px;
	font-weight: 500;
}
.jci-score-tableau-row:last-child { border-bottom: none; }

.jci-score-tableau-footer {
	background: var(--jci-cream);
	padding: 14px 30px;
	display: flex;
	align-items: center;
	justify-content: center;
	border-top: 1px solid var(--jci-border-light);
}

/* ==========================================================================
   12. Generic page / journal post
   ========================================================================== */

.jci-page-inner { max-width: 760px; padding-top: 64px; padding-bottom: 80px; }
.jci-page-header { margin-bottom: 24px; }
.jci-page-header h1 { font-size: clamp(28px, 4vw, 40px); }
.jci-page-thumbnail { margin-bottom: 32px; border-radius: var(--jci-radius); overflow: hidden; }

/* ==========================================================================
   13. 404
   ========================================================================== */

.jci-404 {
	text-align: center;
	padding: 110px 0;
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 16px;
}
.jci-404 h1 { font-size: 34px; margin: 0; }
.jci-404 p { color: var(--jci-muted); margin: 0 0 8px; }

/* ==========================================================================
   14. Footer
   ========================================================================== */

.jci-site-footer { background: var(--jci-navy); color: var(--jci-muted-navy); margin-top: 0; }
.jci-site-footer-inner { padding: 64px 0 32px; display: flex; flex-direction: column; gap: 40px; }
.jci-footer-brand { display: flex; flex-direction: column; gap: 14px; max-width: 420px; }
.jci-footer-tagline { color: var(--jci-muted-navy); font-size: 14px; margin: 0; }

.jci-footer-widgets {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 32px;
	border-top: 1px solid rgba(255,255,255,0.1);
	padding-top: 32px;
}
@media (max-width: 720px) { .jci-footer-widgets { grid-template-columns: 1fr; } }
.jci-footer-widget-title { color: #fff; font-size: 14px; font-family: var(--jci-font-sans); letter-spacing: 0.04em; margin: 0 0 12px; }
.jci-footer-widgets a { color: var(--jci-muted-navy); }
.jci-footer-widgets a:hover { color: var(--jci-red-on-navy); }

.jci-footer-menu { display: flex; flex-wrap: wrap; gap: 20px; }
.jci-footer-menu a { color: var(--jci-muted-navy); font-size: 14px; }
.jci-footer-menu a:hover { color: var(--jci-red-on-navy); }

.jci-footer-bottom {
	display: flex;
	flex-wrap: wrap;
	gap: 8px 24px;
	justify-content: space-between;
	border-top: 1px solid rgba(255,255,255,0.1);
	padding-top: 24px;
	font-size: 12px;
	color: var(--jci-muted-navy);
}

/* ==========================================================================
   15. WordPress core alignment helpers (Gutenberg)
   ========================================================================== */

.alignwide { max-width: calc(var(--jci-container-width) - 48px); margin-left: auto; margin-right: auto; }
.alignfull { width: 100vw; position: relative; left: 50%; right: 50%; margin-left: -50vw; margin-right: -50vw; }
.aligncenter { margin-left: auto; margin-right: auto; }
.wp-caption-text { color: var(--jci-muted); font-size: 13px; }
