/* Nurmijärvi Golf — site theme. Replaces the old Bandon WordPress theme CSS.
   Tokens → base → layout (header, hero, sections, footer) → components. */

:root {
	--green-900: #10211b;
	--green-800: #1a322b;
	--green-700: #24463c;
	--green-100: #e8efea;
	--gold: #cf8018;
	--gold-dark: #a8650f;
	--cream: #f7f4ec;
	--ink: #1f2a26;
	--muted: #5b6863;
	--line: #e4decd;
	--white: #fff;
	--radius: 14px;
	--radius-sm: 8px;
	--shadow: 0 6px 24px rgba(16, 33, 27, .08);
	--shadow-hover: 0 12px 32px rgba(16, 33, 27, .14);
	--font-body: 'Work Sans', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
	--font-head: 'Playfair Display', Georgia, 'Times New Roman', serif;
	--container: 1180px;
	--header-h: 72px;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body { margin: 0; font-family: var(--font-body); font-size: 17px; line-height: 1.65; color: var(--ink); background: var(--white); }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--gold-dark); }
a:hover { color: var(--gold); }
h1, h2, h3, h4 { font-family: var(--font-head); color: var(--green-800); line-height: 1.2; margin: 0 0 .5em; font-weight: 700; }
h1 { font-size: clamp(32px, 4.4vw, 50px); }
h2 { font-size: clamp(25px, 2.8vw, 34px); }
h3 { font-size: clamp(19px, 2vw, 22px); }
p, ul, ol { margin: 0 0 1.1em; }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; }
.skip-link { position: absolute; left: -9999px; top: 8px; background: var(--green-800); color: #fff; padding: 10px 16px; border-radius: var(--radius-sm); z-index: 1000; }
.skip-link:focus { left: 8px; }
.screen-reader-text { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.container { width: 100%; max-width: var(--container); margin: 0 auto; padding: 0 24px; }

/* ---------- Buttons ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 12px 22px; border-radius: 999px; border: 2px solid var(--gold); background: var(--gold); color: #fff; font-family: var(--font-body); font-size: 15px; font-weight: 600; letter-spacing: .2px; text-decoration: none; line-height: 1.2; cursor: pointer; transition: background .2s, border-color .2s, color .2s, transform .2s; }
.btn:hover { background: var(--gold-dark); border-color: var(--gold-dark); color: #fff; }
.btn-outline, .btn-transparent { background: transparent; color: var(--green-800); border-color: var(--green-800); }
.btn-outline:hover, .btn-transparent:hover { background: var(--green-800); border-color: var(--green-800); color: #fff; }
.btn-light { background: #fff; border-color: #fff; color: var(--green-800); }
.btn-light:hover { background: var(--cream); border-color: var(--cream); color: var(--green-800); }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; margin: 8px 0 0; }

/* ---------- Header ---------- */
.site-header { position: sticky; top: 0; z-index: 100; background: #fff; border-bottom: 1px solid var(--line); }
.ng-prose h2[id] { scroll-margin-top: calc(var(--header-h) + 16px); }
.site-header .container { display: flex; align-items: center; justify-content: space-between; gap: 24px; min-height: var(--header-h); }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--green-800); flex-shrink: 0; }
.brand img { width: 42px; height: 42px; border-radius: 50%; background: var(--green-800); padding: 4px; }
.brand-name { font-family: var(--font-head); font-size: 21px; font-weight: 700; line-height: 1.1; }
.brand-name small { display: block; font-family: var(--font-body); font-size: 11px; font-weight: 500; letter-spacing: 1.2px; text-transform: uppercase; color: var(--muted); }
.site-nav ul { list-style: none; margin: 0; padding: 0; display: flex; align-items: center; gap: 4px; }
.site-nav a { display: block; padding: 10px 12px; color: var(--ink); text-decoration: none; font-size: 15px; font-weight: 500; border-radius: var(--radius-sm); }
.site-nav a:hover { color: var(--green-800); background: var(--green-100); }
.site-nav a[aria-current] { color: var(--green-800); box-shadow: inset 0 -3px 0 var(--gold); border-radius: 0; }
.nav-toggle { display: none; align-items: center; gap: 8px; background: none; border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 9px 12px; font: 600 14px var(--font-body); color: var(--green-800); cursor: pointer; }
.nav-toggle-bars { width: 18px; height: 2px; background: currentColor; position: relative; }
.nav-toggle-bars::before, .nav-toggle-bars::after { content: ""; position: absolute; left: 0; width: 18px; height: 2px; background: currentColor; }
.nav-toggle-bars::before { top: -6px; }
.nav-toggle-bars::after { top: 6px; }

@media (max-width: 1020px) {
	.nav-toggle { display: inline-flex; }
	.site-nav { display: none; position: absolute; left: 0; right: 0; top: 100%; background: #fff; border-bottom: 1px solid var(--line); box-shadow: var(--shadow); }
	.site-nav.is-open { display: block; }
	.site-nav ul { flex-direction: column; align-items: stretch; gap: 0; padding: 8px 16px 16px; }
	.site-nav a { padding: 13px 8px; border-bottom: 1px solid var(--line); border-radius: 0; font-size: 16px; }
	.site-nav a[aria-current] { box-shadow: inset 3px 0 0 var(--gold); padding-left: 14px; }
}

/* ---------- Page hero (subpages): text on a solid band, image beside it — never text over photos ---------- */
.page-hero { background: var(--green-800); color: #fff; padding: 48px 0 52px; }
.page-hero .container { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); gap: 48px; align-items: center; }
.page-hero.no-media .container { grid-template-columns: minmax(0, 1fr); }
.page-hero h1 { color: #fff; margin: 0 0 14px; }
.page-hero-lead { font-size: 19px; line-height: 1.6; color: rgba(255, 255, 255, .86); margin: 0; max-width: 620px; }
.page-hero-kicker { display: inline-block; font-size: 12px; font-weight: 600; letter-spacing: 1.4px; text-transform: uppercase; color: var(--gold); margin-bottom: 12px; }
.page-hero-media { margin: 0; }
.page-hero-media img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: var(--radius); box-shadow: 0 16px 40px rgba(0, 0, 0, .25); }
.page-hero-media figcaption { margin-top: 8px; font-size: 12px; letter-spacing: .3px; color: rgba(255, 255, 255, .6); text-align: right; }
@media (max-width: 820px) {
	.page-hero { padding: 32px 0 36px; }
	.page-hero .container { grid-template-columns: minmax(0, 1fr); gap: 24px; }
	.page-hero-media img { aspect-ratio: 16 / 9; }
	.page-hero-lead { font-size: 17px; }
}

/* ---------- Home hero ---------- */
.home-hero { background: var(--cream); padding: 64px 0; }
.home-hero .container { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 56px; align-items: center; }
.home-hero h1 { font-size: clamp(36px, 5vw, 58px); margin-bottom: 18px; }
.home-hero-lead { font-size: 19px; color: var(--muted); max-width: 540px; }
.home-hero-media img { width: 100%; aspect-ratio: 5 / 4; object-fit: cover; border-radius: 22px; box-shadow: var(--shadow-hover); }
@media (max-width: 860px) {
	.home-hero { padding: 36px 0 44px; }
	.home-hero .container { grid-template-columns: minmax(0, 1fr); gap: 28px; }
	.home-hero-media { order: -1; }
	.home-hero-media img { aspect-ratio: 16 / 9; border-radius: var(--radius); }
}

.stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.stat { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; text-align: center; }
.stat strong { display: block; font-family: var(--font-head); font-size: 32px; color: var(--green-800); line-height: 1.1; }
.stat span { font-size: 14px; color: var(--muted); }
@media (max-width: 720px) { .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* ---------- Sections ---------- */
.section { padding: 64px 0; }
.section-alt { background: var(--cream); }
.section-dark { background: var(--green-800); color: rgba(255, 255, 255, .88); }
.section-dark h2, .section-dark h3 { color: #fff; }
.section-head { display: flex; align-items: end; justify-content: space-between; gap: 20px; margin-bottom: 26px; flex-wrap: wrap; }
.section-head h2 { margin: 0; }
.section-head p { margin: 6px 0 0; color: var(--muted); max-width: 640px; }
.section-head .more { font-weight: 600; text-decoration: none; white-space: nowrap; }
.split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 48px; align-items: center; }
.split img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: var(--radius); }
@media (max-width: 820px) { .section { padding: 44px 0; } .split { grid-template-columns: minmax(0, 1fr); gap: 24px; } }

/* ---------- Content (article pages) ---------- */
.ng-section { padding: 40px 0 64px; background: #fff; }
.ng-prose { max-width: 820px; }
.ng-prose h2 { margin: 48px 0 16px; }
.ng-prose h3 { margin: 32px 0 10px; }
.ng-prose ul, .ng-prose ol { padding-left: 22px; }
.ng-prose li { margin-bottom: 6px; }
.ng-prose a:not(.btn):not(.ng-card) { color: var(--gold-dark); text-decoration: underline; text-underline-offset: 2px; }
.ng-lead { font-size: 20px; line-height: 1.6; color: #2b3b35; }
.ng-wide { max-width: none; }

.ng-breadcrumbs ol { list-style: none; padding: 0; margin: 0 0 28px; display: flex; flex-wrap: wrap; gap: 6px; font-size: 13px; letter-spacing: .3px; }
.ng-breadcrumbs li { margin: 0; color: var(--muted); }
.ng-breadcrumbs li + li::before { content: "›"; margin-right: 6px; color: #a3aaa6; }
.ng-prose .ng-breadcrumbs a { color: var(--muted); text-decoration: none; }
.ng-prose .ng-breadcrumbs a:hover { color: var(--green-800); text-decoration: underline; }
.ng-breadcrumbs [aria-current] { color: var(--green-800); font-weight: 600; }

.ng-table-wrap { overflow-x: auto; margin: 0 0 24px; -webkit-overflow-scrolling: touch; border: 1px solid var(--line); border-radius: var(--radius-sm); }
.ng-table { width: 100%; border-collapse: collapse; font-size: 15px; line-height: 1.5; }
.ng-table th, .ng-table td { padding: 11px 14px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
.ng-table tr:last-child th, .ng-table tr:last-child td { border-bottom: 0; }
.ng-table thead th { background: var(--green-800); color: #fff; font-weight: 600; white-space: nowrap; }
.ng-table tbody th { font-weight: 600; color: var(--green-800); }
.ng-table tbody tr:nth-child(even) { background: #fbfaf6; }

.ng-facts { background: var(--cream); border-left: 4px solid var(--gold); border-radius: var(--radius-sm); padding: 18px 22px; margin: 24px 0; }
.ng-facts dl { display: grid; grid-template-columns: max-content 1fr; gap: 6px 20px; margin: 0; }
.ng-facts dt { font-weight: 600; color: var(--green-800); }
.ng-facts dd { margin: 0; }
@media (max-width: 600px) {
	body { font-size: 16px; }
	.ng-facts dl { grid-template-columns: 1fr; gap: 0; }
	.ng-facts dd { margin-bottom: 10px; }
	.ng-lead { font-size: 18px; }
}

.ng-note { font-size: 14px; line-height: 1.6; color: var(--muted); background: #f3f5f4; border-radius: var(--radius-sm); padding: 14px 18px; margin: 30px 0; }
.ng-disclosure { font-size: 13px; color: var(--muted); margin: -10px 0 24px; }
.ng-aff-btn { padding: 8px 14px; font-size: 13px; white-space: nowrap; }

/* ---------- Cards: fixed image ratio so every photo fits ---------- */
.ng-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 24px; margin: 20px 0 34px; }
.ng-card { display: flex; flex-direction: column; border-radius: var(--radius); overflow: hidden; background: #fff; border: 1px solid var(--line); color: inherit; text-decoration: none; transition: transform .2s, box-shadow .2s; }
.ng-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-hover); color: inherit; }
.ng-card img { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; }
.ng-card-body { padding: 18px 20px 22px; }
.ng-card-meta { font-size: 12px; font-weight: 600; letter-spacing: .8px; text-transform: uppercase; color: var(--gold-dark); margin: 0 0 6px; }
.ng-card h3 { margin: 0 0 8px; font-size: 20px; }
.ng-prose .ng-card h3 { margin: 0 0 8px; }
.ng-card p { margin: 0; font-size: 15px; line-height: 1.55; color: var(--muted); }

.ng-faq details { border-bottom: 1px solid var(--line); padding: 14px 0; }
.ng-faq summary { cursor: pointer; font-weight: 600; color: var(--green-800); list-style: none; }
.ng-faq summary::-webkit-details-marker { display: none; }
.ng-faq summary::before { content: "+"; display: inline-block; width: 1.3em; color: var(--gold); font-weight: 700; }
.ng-faq details[open] summary::before { content: "–"; }
.ng-faq details > div { margin-top: 10px; }

.ng-az { display: flex; flex-wrap: wrap; gap: 6px; margin: 10px 0 30px; }
.ng-prose .ng-az a { display: inline-block; min-width: 36px; text-align: center; padding: 6px 8px; border: 1px solid var(--line); border-radius: 6px; text-decoration: none; color: var(--green-800); font-weight: 600; }
.ng-prose .ng-az a:hover { background: var(--green-100); }
.ng-glossary dt { font-weight: 700; color: var(--green-800); margin-top: 18px; scroll-margin-top: calc(var(--header-h) + 16px); }
.ng-glossary dd { margin: 4px 0 0; }
.ng-glossary h2 { scroll-margin-top: calc(var(--header-h) + 16px); }

.ng-grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; }
.ng-panel { background: var(--cream); border-radius: var(--radius); padding: 24px; }
.ng-panel h3 { margin-top: 0; }
@media (max-width: 720px) { .ng-grid-2 { grid-template-columns: minmax(0, 1fr); } }

/* ---------- Forms ---------- */
.contact-form label { display: block; font-weight: 600; margin: 18px 0 6px; }
.contact-form input[type="text"], .contact-form input[type="email"], .contact-form select, .contact-form textarea { width: 100%; padding: 12px 14px; border: 1px solid #d8d2c0; border-radius: var(--radius-sm); font: inherit; font-size: 16px; background: #fff; color: var(--ink); }

/* ---------- Footer ---------- */
.site-footer { background: var(--green-900); color: rgba(255, 255, 255, .78); padding: 56px 0 28px; font-size: 15px; }
.site-footer a { color: rgba(255, 255, 255, .86); text-decoration: none; }
.site-footer a:hover { color: #fff; text-decoration: underline; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 36px; }
.footer-grid h2 { font-family: var(--font-body); font-size: 13px; font-weight: 600; letter-spacing: 1.2px; text-transform: uppercase; color: var(--gold); margin: 0 0 14px; }
.footer-grid ul { list-style: none; margin: 0; padding: 0; }
.footer-grid li { margin-bottom: 8px; }
.footer-brand .brand { color: #fff; margin-bottom: 14px; }
.footer-brand .brand-name small { color: rgba(255, 255, 255, .6); }
.footer-bottom { border-top: 1px solid rgba(255, 255, 255, .12); margin-top: 40px; padding-top: 20px; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; font-size: 13px; color: rgba(255, 255, 255, .6); }
/* Fixed column counts for card rows: cards($list, 3) / cards($list, 4) */
.ng-cards.ng-cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.ng-cards.ng-cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
@media (max-width: 980px) { .ng-cards.ng-cols-3, .ng-cards.ng-cols-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .ng-cards.ng-cols-3, .ng-cards.ng-cols-4 { grid-template-columns: minmax(0, 1fr); } }

/* Product tables keep readable columns and scroll sideways on phones */
.ng-product-table { min-width: 680px; }

@media (max-width: 860px) { .footer-grid { grid-template-columns: 1fr 1fr; } .footer-brand { grid-column: 1 / -1; } }
@media (max-width: 480px) { .footer-grid { grid-template-columns: 1fr; } }
