/*
Theme Name: The Marbella Post
Description: Luxury editorial theme for The Marbella Post.
Version: 1.1.0
Requires at least: 6.4
Requires PHP: 8.0
License: GPL-2.0-or-later
Text Domain: marbellapost
*/

@font-face { font-family: "Bodoni Moda"; src: url("assets/fonts/BodoniModa-VF.ttf") format("truetype"); font-weight: 400 900; font-style: normal; font-display: swap; }
@font-face { font-family: "Bodoni Moda"; src: url("assets/fonts/BodoniModa-Italic-VF.ttf") format("truetype"); font-weight: 400 900; font-style: italic; font-display: swap; }
@font-face { font-family: "Source Serif 4"; src: url("assets/fonts/SourceSerif4Variable-Roman.ttf.woff2") format("woff2"); font-weight: 200 900; font-style: normal; font-display: swap; }
@font-face { font-family: "Source Serif 4"; src: url("assets/fonts/SourceSerif4Variable-Italic.ttf.woff2") format("woff2"); font-weight: 200 900; font-style: italic; font-display: swap; }
@font-face { font-family: "Manrope"; src: url("assets/fonts/Manrope-VariableFont_wght.woff2") format("woff2"); font-weight: 200 800; font-style: normal; font-display: swap; }

:root {
	--ink: #0b0b0b;
	--paper: #faf8f4;
	--gold: #b08d57;
	--gold-dark: #7a5a2c;
	--stone: #524d46;
	--rule: #e4ded3;
	--display: "Bodoni Moda", Didot, "Bodoni 72", "Times New Roman", serif;
	--serif: "Source Serif 4", Georgia, serif;
	--head: "Source Serif 4", Georgia, serif;
	--sans: "Manrope", system-ui, -apple-system, "Segoe UI", sans-serif;
	--wide: 1240px;
	--read: 680px;
	--gutter: clamp(16px, 4vw, 40px);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--paper); color: var(--ink); font-family: var(--sans); font-size: 16px; line-height: 1.6; -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; }
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
a:hover { color: var(--gold-dark); }
.screen-reader-text { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(1px, 1px, 1px, 1px); white-space: nowrap; }
.skip-link:focus { position: fixed; top: 8px; left: 8px; z-index: 100; background: var(--ink); color: var(--paper); padding: 8px 14px; clip: auto; width: auto; height: auto; }

.wrap { max-width: var(--wide); margin: 0 auto; padding: 0 var(--gutter); }
.label, .kicker, .meta, .mp-nav a, .topbar { font-family: var(--sans); text-transform: uppercase; letter-spacing: .1em; font-size: 13px; font-weight: 700; }
.kicker { color: var(--gold-dark); display: inline-block; margin-bottom: 12px; }
.meta { color: var(--stone); font-weight: 600; letter-spacing: .08em; }

/* Header */
.topbar { border-bottom: 1px solid var(--rule); color: var(--stone); }
.topbar .wrap { display: flex; justify-content: space-between; align-items: center; gap: 16px; min-height: 38px; }
.topbar .where { display: none; }
.lang { display: flex; gap: 10px; }
.lang a { color: var(--stone); }
.lang a.current { color: var(--ink); border-bottom: 1px solid var(--gold); }
.masthead { text-align: center; padding: clamp(22px, 4vw, 44px) 0 clamp(14px, 2.5vw, 26px); }
.wordmark { font-family: var(--display); font-weight: 500; font-size: clamp(30px, 7.2vw, 82px); letter-spacing: .06em; line-height: 1; text-transform: uppercase; margin: 0; font-optical-sizing: auto; }
.wordmark a:hover { color: var(--ink); }
.tagline { font-family: var(--serif); font-style: italic; color: var(--stone); margin: 12px 0 0; font-size: clamp(15px, 1.7vw, 18px); }
.mp-nav { border-top: 1px solid var(--ink); border-bottom: 1px solid var(--rule); }
.mp-nav ul { list-style: none; margin: 0 auto; padding: 0 var(--gutter); display: flex; gap: clamp(18px, 2.6vw, 34px); justify-content: center; overflow-x: auto; scrollbar-width: none; max-width: var(--wide); }
.mp-nav ul::-webkit-scrollbar { display: none; }
.mp-nav li { flex: 0 0 auto; }
.mp-nav a { display: block; padding: 15px 0 13px; border-bottom: 2px solid transparent; }
.mp-nav a:hover, .mp-nav a.current { color: var(--ink); border-bottom-color: var(--gold); }
@media (max-width: 760px) { .mp-nav ul { justify-content: flex-start; } }
@media (min-width: 760px) { .topbar .where { display: block; } }

/* Section labels */
.section { padding: clamp(36px, 6vw, 72px) 0 0; }
.section-head { display: flex; align-items: center; gap: 18px; margin-bottom: 28px; }
.section-head::before, .section-head::after { content: ""; flex: 1; height: 1px; background: var(--rule); }
.section-head h2 { font-family: var(--head); font-weight: 700; font-size: clamp(20px, 2.2vw, 26px); letter-spacing: .06em; margin: 0; text-transform: uppercase; }
.section-head .more { font-family: var(--sans); font-size: 13px; letter-spacing: .1em; text-transform: uppercase; color: var(--gold-dark); font-weight: 600; white-space: nowrap; }
.section-head.left::before { display: none; }

/* Media */
.media { position: relative; overflow: hidden; background: #1a1714; }
.media img { width: 100%; height: 100%; object-fit: cover; transition: transform .8s ease; }
a:hover .media img { transform: scale(1.03); }
.r-hero { aspect-ratio: 4 / 3; }
.r-32 { aspect-ratio: 3 / 2; }
.r-43 { aspect-ratio: 4 / 3; }
@media (min-width: 760px) { .r-hero { aspect-ratio: 21 / 9; } }

/* Lead story */
.lead { padding-top: clamp(20px, 3vw, 36px); }
.lead-text { max-width: 900px; margin: 0 auto; text-align: center; padding: clamp(22px, 3.5vw, 40px) 0 0; }
.lead-title { font-family: var(--head); font-weight: 700; font-size: clamp(32px, 5.6vw, 66px); line-height: 1.06; letter-spacing: -.005em; margin: 0 0 18px; }
.lead-dek { font-family: var(--serif); font-style: italic; font-size: clamp(17px, 1.9vw, 21px); color: #3d3934; line-height: 1.55; margin: 0 auto 18px; max-width: 720px; }

/* Cards */
.grid { display: grid; gap: clamp(28px, 3.4vw, 44px) clamp(20px, 2.6vw, 36px); grid-template-columns: 1fr; }
@media (min-width: 640px) { .grid-3, .grid-4 { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 960px) { .grid-3 { grid-template-columns: repeat(3, 1fr); } .grid-4 { grid-template-columns: repeat(4, 1fr); } }
.card .media { margin-bottom: 16px; }
.card-title { font-family: var(--head); font-weight: 700; font-size: clamp(21px, 2vw, 26px); line-height: 1.18; margin: 0 0 10px; }
.grid-4 .card-title { font-size: clamp(18px, 1.6vw, 20px); }
.card-dek { font-family: var(--serif); color: #2f2b26; font-size: 17px; line-height: 1.6; margin: 0 0 12px; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.card .meta { font-size: 12px; }

/* Ink band */
.band { background: var(--ink); color: var(--paper); margin-top: clamp(48px, 7vw, 88px); padding: clamp(40px, 6vw, 70px) 0; }
.band .section-head::before, .band .section-head::after { background: #3a352f; }
.band .card-dek { color: #d6cfc3; }
.band .meta { color: #b9b1a5; }
.band a:hover { color: var(--gold); }

/* Article */
.article-head { max-width: 900px; margin: 0 auto; text-align: center; padding: clamp(36px, 6vw, 72px) 0 clamp(24px, 3vw, 36px); }
.article-title { font-family: var(--head); font-weight: 700; font-size: clamp(34px, 5.4vw, 64px); line-height: 1.07; margin: 0 0 22px; }
.standfirst { font-family: var(--serif); font-style: italic; font-size: clamp(18px, 2vw, 22px); line-height: 1.55; color: #3d3934; margin: 0 auto 24px; max-width: 740px; }
.byline { display: inline-flex; gap: 14px; flex-wrap: wrap; justify-content: center; border-top: 1px solid var(--rule); padding-top: 16px; }
.byline strong { color: var(--ink); font-weight: 700; }
.article-figure { max-width: 1100px; margin: 0 auto; }
.article-figure .media { aspect-ratio: 16 / 9; }
.article-figure figcaption { font-family: var(--sans); font-size: 14px; color: var(--stone); padding: 10px 0 0; letter-spacing: .02em; }
.content { max-width: var(--read); margin: 0 auto; padding: clamp(28px, 4vw, 48px) 0 0; font-family: var(--serif); font-size: clamp(19px, 1.35vw, 20px); line-height: 1.7; color: #141210; }
.content > p:first-of-type::first-letter { font-family: var(--head); float: left; font-size: 4.6em; line-height: .82; padding: .06em .1em 0 0; color: var(--ink); font-weight: 700; }
.content h2, .content h3 { font-family: var(--head); font-weight: 700; line-height: 1.2; margin: 1.8em 0 .6em; }
.content h2 { font-size: 1.6em; } .content h3 { font-size: 1.3em; }
.content a { color: var(--ink); text-decoration: underline; text-decoration-color: var(--gold); text-underline-offset: 3px; }
.content blockquote { margin: 1.6em 0; padding: 0 0 0 24px; border-left: 2px solid var(--gold); font-style: italic; font-size: 1.12em; }
.content .source-credit { font-family: var(--sans); font-size: 15px; color: var(--stone); border-top: 1px solid var(--rule); padding-top: 18px; margin-top: 36px; }
.content .source-credit em { font-style: normal; }
.share { max-width: var(--read); margin: 30px auto 0; display: flex; gap: 22px; flex-wrap: wrap; align-items: center; border-top: 1px solid var(--ink); padding-top: 16px; }
.share a { color: var(--stone); }
.share a:hover { color: var(--ink); }

/* Archive / page */
.archive-head { text-align: center; padding: clamp(36px, 6vw, 70px) 0 clamp(28px, 4vw, 44px); border-bottom: 1px solid var(--rule); margin-bottom: clamp(30px, 4vw, 48px); }
.archive-title { font-family: var(--head); font-weight: 700; font-size: clamp(38px, 6vw, 72px); line-height: 1.05; margin: 0; }
.archive-head p { font-family: var(--serif); font-style: italic; color: var(--stone); margin: 14px 0 0; }
.pagination { display: flex; justify-content: center; gap: 18px; padding: 48px 0 0; font-family: var(--sans); font-size: 12px; letter-spacing: .16em; text-transform: uppercase; }
.pagination .current { color: var(--gold-dark); }
.empty { text-align: center; font-family: var(--serif); font-style: italic; color: var(--stone); padding: 40px 0; }
.search-form { display: flex; max-width: 520px; margin: 0 auto; border-bottom: 1px solid var(--ink); }
.search-form input[type=search] { flex: 1; border: 0; background: transparent; font-family: var(--serif); font-size: 18px; padding: 10px 0; outline: none; color: var(--ink); }
.search-form button { border: 0; background: none; font-family: var(--sans); text-transform: uppercase; letter-spacing: .1em; font-size: 13px; font-weight: 700; cursor: pointer; color: var(--ink); }

/* Footer */
.site-footer { background: var(--ink); color: #cfc8bb; margin-top: clamp(60px, 8vw, 110px); padding: clamp(48px, 6vw, 76px) 0 28px; }
.band + .site-footer { margin-top: 0; border-top: 1px solid #2a2622; }
.site-footer .wordmark { color: var(--paper); font-size: clamp(26px, 3.6vw, 40px); }
.site-footer .tagline { color: #9c9488; }
.footer-cols { display: grid; grid-template-columns: 1fr; gap: 32px; margin-top: 40px; padding-top: 32px; border-top: 1px solid #2a2622; }
@media (min-width: 760px) { .footer-cols { grid-template-columns: 2fr 1fr 1fr 1fr; } }
.footer-cols h3 { font-family: var(--sans); font-size: 13px; letter-spacing: .1em; text-transform: uppercase; color: var(--gold); margin: 0 0 14px; font-weight: 700; }
.footer-cols ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; font-size: 16px; }
.footer-cols a:hover { color: var(--paper); }
.footer-about { font-family: var(--serif); font-size: 17px; line-height: 1.65; color: #cdc5b8; max-width: 420px; margin: 0; }
.footer-bottom { margin-top: 44px; padding-top: 20px; border-top: 1px solid #2a2622; display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px; font-size: 12px; color: #8a8378; }

/* Background box ("Who is ...") and links to related coverage */
.content .mp-background { font-family: var(--sans); font-size: 16px; line-height: 1.6; color: #2a2722; background: #f1ece2; border-top: 3px solid var(--gold); padding: 18px 22px 20px; margin: 2em 0; }
.content .mp-background .mp-bg-label { display: block; font-size: 12px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--gold-dark); margin-bottom: 10px; }
.content .mp-background h4 { font-family: var(--head); font-size: 19px; font-weight: 700; margin: 0 0 6px; color: var(--ink); }
.content .mp-background p { margin: 0 0 12px; }
.content .mp-background p:last-child { margin-bottom: 0; }
@media (min-width: 1280px) {
	.content .mp-background { float: right; clear: right; width: 250px; margin: .3em -290px 1.5em 0; }
}
.content a.mp-tag-link { text-decoration-style: dotted; }
.ai-note { max-width: var(--read); margin: 22px auto 0; font-family: var(--sans); font-size: 14px; color: var(--stone); line-height: 1.55; }
.ai-note a { color: var(--ink); text-decoration: underline; text-decoration-color: var(--gold); text-underline-offset: 3px; }

/* Reader tip form */
.mp-tip-form { display: grid; gap: 18px; font-family: var(--sans); font-size: 16px; margin-top: 1.5em; }
.mp-tip-form label { display: grid; gap: 6px; font-weight: 600; font-size: 15px; color: var(--ink); }
.mp-tip-form input[type=text], .mp-tip-form select, .mp-tip-form textarea { font: inherit; font-weight: 400; padding: 12px 14px; border: 1px solid #cfc7b8; background: #fff; color: var(--ink); border-radius: 0; width: 100%; box-sizing: border-box; }
.mp-tip-form textarea { resize: vertical; }
.mp-tip-form input:focus, .mp-tip-form select:focus, .mp-tip-form textarea:focus { outline: 2px solid var(--gold); outline-offset: 1px; }
.mp-tip-row { display: grid; gap: 18px; grid-template-columns: 1fr; }
@media (min-width: 640px) { .mp-tip-row { grid-template-columns: 1fr 1fr; } }
.mp-tip-form .mp-check { display: flex; gap: 10px; align-items: flex-start; font-weight: 400; font-size: 14px; color: #3d3934; line-height: 1.5; }
.mp-tip-form .mp-check input { margin-top: 4px; }
.mp-tip-form button { justify-self: start; background: var(--ink); color: var(--paper); border: 0; padding: 15px 28px; font-family: var(--sans); font-size: 13px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; cursor: pointer; }
.mp-tip-form button:hover { background: var(--gold-dark); }
.mp-hp { position: absolute; left: -9999px; height: 0; overflow: hidden; }
.mp-tip-ok, .mp-tip-error { font-family: var(--sans); font-size: 16px; padding: 16px 20px; margin: 1em 0; border-left: 3px solid var(--gold); background: #f1ece2; }
.mp-tip-error { border-left-color: #b3261e; }
.page-content > p:first-of-type::first-letter { float: none; font-size: inherit; line-height: inherit; padding: 0; font-family: inherit; font-weight: inherit; color: inherit; }

/* Cookie consent */
.mp-consent { position: fixed; left: 16px; right: 16px; bottom: 16px; z-index: 50; max-width: 560px; margin: 0 auto; background: var(--ink); color: #e9e3d8; padding: 18px 20px; font-family: var(--sans); font-size: 15px; line-height: 1.55; box-shadow: 0 10px 30px rgba(0,0,0,.25); border-top: 2px solid var(--gold); }
.mp-consent[hidden] { display: none; }
.mp-consent p { margin: 0 0 14px; }
.mp-consent a { color: var(--gold); text-decoration: underline; }
.mp-consent-buttons { display: flex; gap: 10px; }
.mp-consent-buttons button { flex: 1; padding: 12px 14px; font-family: var(--sans); font-size: 13px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; cursor: pointer; border: 1px solid #e9e3d8; background: transparent; color: #e9e3d8; }
.mp-consent-buttons button[data-mp-consent="yes"] { background: #e9e3d8; color: var(--ink); }
.mp-consent-buttons button:hover { border-color: var(--gold); }
