/*
Theme Name: Kendisportal
Theme URI: https://kendisportal.com
Author: Kendisportal
Author URI: https://kendisportal.com
Description: 
Version: 1.0.0
Requires at least: 6.0
Tested up to: 6.6
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: spotlight
Tags: blog, news, magazine, editorial, two-columns, three-columns, right-sidebar, custom-logo, custom-menu, featured-images, translation-ready
*/

/* =========================================================
   1. Design tokens
   ========================================================= */
:root {
	--black: #0a0a0a;
	--ink: #17161a;
	--body: #2b2a2e;
	--muted: #6f6d73;
	--faint: #9a989d;
	--line: #e6e4e2;
	--line-strong: #17161a;
	--bg: #ffffff;
	--placeholder: #ececec;

	--serif: "Playfair Display", Georgia, "Times New Roman", serif;
	--sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif;

	--maxw: 1360px;
	--wrap: 720px;
	--wrap-wide: 1000px;
	--gutter: 28px;

	--eyebrow: 0.72rem;
}

/* =========================================================
   2. Reset / base
   ========================================================= */
*, *::before, *::after { box-sizing: border-box; }

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

body {
	margin: 0;
	background: var(--bg);
	color: var(--body);
	font-family: var(--sans);
	font-size: 17px;
	line-height: 1.6;
	-webkit-font-smoothing: antialiased;
	-moz-osx-font-smoothing: grayscale;
	text-rendering: optimizeLegibility;
}

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

a { color: inherit; text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 3px; }

h1, h2, h3, h4 { margin: 0; font-weight: 500; }

figure { margin: 0; }

.container {
	max-width: var(--maxw);
	margin: 0 auto;
	padding: 0 var(--gutter);
}

.screen-reader-text {
	position: absolute !important;
	clip-path: inset(50%);
	width: 1px; height: 1px;
	overflow: hidden;
	white-space: nowrap;
}
.skip-link:focus {
	position: fixed; top: 8px; left: 8px;
	clip-path: none; width: auto; height: auto;
	background: var(--black); color: #fff;
	padding: 10px 16px; z-index: 1000;
}

/* Shared editorial pieces --------------------------------- */
.eyebrow {
	font-family: var(--sans);
	font-size: var(--eyebrow);
	font-weight: 700;
	letter-spacing: 0.13em;
	text-transform: uppercase;
	color: var(--ink);
	display: inline-block;
}
a.eyebrow:hover { text-decoration: none; opacity: 0.65; }

.rule-top { border: 0; border-top: 1px solid var(--line-strong); margin: 0; }
.rule-hair { border: 0; border-top: 1px solid var(--line); margin: 0; }

.reading-time { display: inline-flex; align-items: center; gap: 6px; }
.reading-time svg { width: 13px; height: 13px; opacity: 0.7; }

/* =========================================================
   3. Topbar
   ========================================================= */
.topbar {
	background: var(--black);
	color: #fff;
}
.topbar__inner {
	display: flex;
	justify-content: space-between;
	align-items: center;
	gap: 20px;
	padding: 11px 0;
	font-size: 12.5px;
	letter-spacing: 0.02em;
}
.topbar__right { color: #d7d5d2; }

/* =========================================================
   4. Header
   ========================================================= */
.site-header { border-bottom: 1px solid var(--line); }
.site-header__inner {
	display: grid;
	grid-template-columns: 1fr auto 1fr;
	align-items: center;
	gap: 24px;
	padding: 26px 0 22px;
}
.site-header__left { justify-self: start; }
.site-header__brand { justify-self: center; text-align: center; }
.site-header__right { justify-self: end; }

.brand-word,
.brand-word:hover {
	font-family: var(--serif);
	font-weight: 500;
	font-size: clamp(2rem, 4.4vw, 3.05rem);
	line-height: 1;
	letter-spacing: 0.16em;
	text-transform: uppercase;
	color: var(--ink);
	text-decoration: none;
	white-space: nowrap;
	padding-left: 0.16em; /* optical: compensate tracking */
}
.custom-logo-link { display: inline-block; }
.custom-logo-link img { max-height: 58px; width: auto; }

.search-form {
	display: flex;
	align-items: center;
	gap: 9px;
	border: 1px solid #d8d6d3;
	border-radius: 3px;
	padding: 9px 14px;
	max-width: 280px;
}
.search-form__icon { display: inline-flex; color: var(--faint); }
.search-form__icon svg { width: 16px; height: 16px; }
.search-form__input {
	border: 0;
	outline: none;
	background: transparent;
	font: inherit;
	font-size: 14px;
	width: 100%;
	color: var(--ink);
}
.search-form__input::placeholder { color: var(--faint); }

.btn-subscribe,
.btn-subscribe:hover {
	display: inline-block;
	background: var(--black);
	color: #fff;
	font-size: 14px;
	letter-spacing: 0.01em;
	padding: 12px 24px;
	border-radius: 3px;
	text-decoration: none;
	white-space: nowrap;
}
.btn-subscribe:hover { background: #262528; }

/* Nav ----------------------------------------------------- */
.site-nav { padding-bottom: 20px; }
.site-nav__inner { display: flex; justify-content: center; }

.nav-menu {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	align-items: center;
	gap: clamp(22px, 3.4vw, 64px);
}
.nav-menu li { margin: 0; }
.nav-menu a {
	font-size: 15px;
	font-weight: 500;
	color: var(--ink);
	text-decoration: none;
	letter-spacing: 0.01em;
}
.nav-menu a:hover { text-decoration: underline; text-underline-offset: 4px; }
.nav-menu .current-menu-item > a,
.nav-menu .current-cat > a { text-decoration: underline; text-underline-offset: 4px; }
.nav-menu ul { display: none; } /* sub-menus not part of this design */

.nav-toggle {
	display: none;
	align-items: center;
	gap: 9px;
	background: none;
	border: 0;
	font: inherit;
	font-size: 14px;
	font-weight: 600;
	letter-spacing: 0.04em;
	text-transform: uppercase;
	color: var(--ink);
	cursor: pointer;
	padding: 6px 0;
}
.nav-toggle span,
.nav-toggle span::before,
.nav-toggle span::after {
	content: "";
	display: block;
	width: 20px;
	height: 2px;
	background: var(--ink);
	position: relative;
	transition: transform 0.2s ease, opacity 0.2s ease;
}
.nav-toggle span::before { position: absolute; top: -6px; }
.nav-toggle span::after { position: absolute; top: 6px; }

/* =========================================================
   5. Site main spacing
   ========================================================= */
.site-main { display: block; }

/* =========================================================
   6. Front page
   ========================================================= */
.home-hero {
	display: grid;
	grid-template-columns: 1fr 2.15fr 1.2fr;
	gap: 52px;
	padding-top: 44px;
}

/* -- Left: Det seneste -- */
.block-title {
	font-family: var(--serif);
	font-style: italic;
	font-weight: 500;
	font-size: 1.7rem;
	line-height: 1.1;
	padding-top: 16px;
	margin-bottom: 4px;
}
.block-title--label {
	font-family: var(--sans);
	font-style: normal;
	font-weight: 700;
	font-size: var(--eyebrow);
	letter-spacing: 0.14em;
	text-transform: uppercase;
}

.latest-list { display: block; }
.mini {
	display: flex;
	gap: 16px;
	align-items: flex-start;
	padding: 20px 0;
	border-bottom: 1px solid var(--line);
}
.mini__media {
	flex: 0 0 66px;
	width: 66px;
	height: 66px;
	overflow: hidden;
	background: var(--placeholder);
}
.mini__media img { width: 100%; height: 100%; object-fit: cover; }
.mini__body { min-width: 0; }
.mini__title {
	font-family: var(--serif);
	font-weight: 500;
	font-size: 1.28rem;
	line-height: 1.16;
	color: var(--ink);
}
.mini a:hover .mini__title { text-decoration: underline; text-underline-offset: 3px; }
.mini__meta {
	margin-top: 9px;
	font-size: 11px;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: var(--muted);
}

/* -- Center: hero -- */
.hero__media { overflow: hidden; }
.hero__media img { width: 100%; aspect-ratio: 3 / 2.05; object-fit: cover; }
.hero__cat { margin-top: 22px; }
.hero__title {
	font-family: var(--serif);
	font-weight: 500;
	font-size: clamp(2.3rem, 4.2vw, 3.65rem);
	line-height: 1.04;
	letter-spacing: -0.005em;
	color: var(--ink);
	margin: 0.28em 0 0.32em;
}
.hero__title a:hover { text-decoration: none; opacity: 0.82; }
.hero__dek {
	font-size: 1.2rem;
	line-height: 1.55;
	color: #3c3a3f;
	max-width: 46ch;
	margin: 0;
}
.hero__byline {
	margin-top: 22px;
	font-size: 12px;
	letter-spacing: 0.09em;
	text-transform: uppercase;
	color: var(--muted);
}

/* -- Right: Mest læste -- */
.mostread { display: block; }
.mr-item {
	padding: 22px 0;
	border-bottom: 1px solid var(--line);
}
.mr-item:first-of-type { padding-top: 18px; }
.mr-item__media {
	overflow: hidden;
	background: var(--placeholder);
	margin-bottom: 16px;
}
.mr-item__media img { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; }
.mr-item__cat { margin-bottom: 8px; }
.mr-item__title {
	display: block;
	font-family: var(--serif);
	font-weight: 500;
	font-size: 1.5rem;
	line-height: 1.14;
	color: var(--ink);
	margin-top: 6px;
}
.mr-item a:hover .mr-item__title { text-decoration: underline; text-underline-offset: 3px; }
.mr-item__dek {
	margin: 10px 0 0;
	font-size: 0.92rem;
	color: var(--muted);
	line-height: 1.45;
}

/* -- Nyt på Spotlight section -- */
.section {
	padding-top: 8px;
	margin-top: 72px;
}
.section__head {
	display: flex;
	justify-content: space-between;
	align-items: baseline;
	gap: 24px;
	border-top: 2px solid var(--line-strong);
	padding-top: 28px;
}
.section__title {
	font-family: var(--serif);
	font-weight: 500;
	font-size: clamp(1.9rem, 3.6vw, 3rem);
	line-height: 1.05;
	color: var(--ink);
}
.section__more {
	flex: 0 0 auto;
	font-size: var(--eyebrow);
	font-weight: 700;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	color: var(--ink);
	text-decoration: underline;
	text-underline-offset: 4px;
}

/* -- Card grid -- */
.cards-grid {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 44px;
	margin-top: 36px;
}
.card { display: block; color: inherit; }
.card__media {
	overflow: hidden;
	background: var(--placeholder);
	margin-bottom: 18px;
}
.card__media img { width: 100%; aspect-ratio: 16 / 11; object-fit: cover; transition: transform 0.4s ease; }
.card:hover .card__media img { transform: scale(1.03); }
.card__placeholder { width: 100%; aspect-ratio: 16 / 11; background: var(--placeholder); }
.card__cat { margin-bottom: 11px; }
.card__title {
	font-family: var(--serif);
	font-weight: 500;
	font-size: 1.62rem;
	line-height: 1.14;
	color: var(--ink);
}
.card:hover .card__title { text-decoration: underline; text-underline-offset: 3px; }
.card__dek {
	margin: 12px 0 0;
	font-size: 0.98rem;
	color: var(--muted);
	line-height: 1.5;
}

/* =========================================================
   7. Article (single) + page template
   ========================================================= */
.article-wrap {
	max-width: var(--wrap);
	margin: 0 auto;
	padding: 0 var(--gutter);
}
.post--single, .post--page { padding-top: 8px; }

.article-head { text-align: center; }
.article-head .rule-top { margin: 42px 0 22px; }
.article-head .eyebrow { display: block; }
.article-title {
	font-family: var(--serif);
	font-weight: 500;
	font-size: clamp(2.5rem, 6vw, 4.4rem);
	line-height: 1.03;
	letter-spacing: -0.01em;
	color: var(--ink);
	margin: 0.16em auto 0.34em;
	max-width: 15ch;
}
.article-meta {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	align-items: center;
	gap: 12px;
	font-size: 13px;
	color: var(--muted);
}
.article-meta__author { color: var(--ink); font-weight: 600; }
.article-meta .dot { color: var(--faint); }

.article-hero { margin: 36px auto 0; }
.article-hero img { width: 100%; height: auto; }

.article-body {
	margin-top: 38px;
	font-size: 1.13rem;
	line-height: 1.75;
	color: var(--body);
}
.article-body > *:first-child { margin-top: 0; }
.article-body p { margin: 0 0 1.5em; }
.article-body p:first-of-type { font-size: 1.2rem; line-height: 1.65; color: #37363b; }
.article-body h2 {
	font-family: var(--serif);
	font-style: italic;
	font-weight: 500;
	font-size: 1.72rem;
	line-height: 1.2;
	color: var(--ink);
	margin: 1.9em 0 0.7em;
}
.article-body h3 {
	font-family: var(--serif);
	font-weight: 600;
	font-size: 1.35rem;
	line-height: 1.25;
	color: var(--ink);
	margin: 1.7em 0 0.6em;
}
.article-body h4 {
	font-family: var(--sans);
	font-weight: 700;
	font-size: 0.8rem;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	margin: 1.8em 0 0.6em;
}
.article-body a { text-decoration: underline; text-underline-offset: 2px; }
.article-body ul, .article-body ol { margin: 0 0 1.5em; padding-left: 1.3em; }
.article-body li { margin: 0 0 0.7em; padding-left: 0.2em; }
.article-body blockquote {
	margin: 2em 0;
	padding: 0.15em 0 0.15em 24px;
	border-left: 3px solid var(--ink);
	font-family: var(--serif);
	font-style: italic;
	font-size: 1.28rem;
	line-height: 1.5;
	color: #3a383d;
}
.article-body blockquote p { margin: 0; }
.article-body blockquote cite { display: block; margin-top: 0.6em; font-size: 0.85rem; font-style: normal; color: var(--muted); }
.article-body img,
.article-body .wp-block-image { margin: 2em 0; }
.article-body figcaption { font-size: 0.85rem; color: var(--muted); margin-top: 0.6em; text-align: center; }
.article-body pre { background: #f5f4f2; padding: 18px; overflow: auto; border-radius: 3px; font-size: 0.9rem; }
.article-body code { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 0.9em; }

.wp-link-pages { margin: 2em 0; font-size: 0.9rem; letter-spacing: 0.02em; }
.wp-link-pages a { text-decoration: underline; }

/* Read also ---------------------------------------------- */
.read-also {
	max-width: var(--wrap-wide);
	margin: 76px auto 0;
	padding: 0 var(--gutter);
}
.read-also .rule-hair { margin-bottom: 30px; }
.read-also__title {
	font-family: var(--serif);
	font-weight: 500;
	font-size: 1.9rem;
	color: var(--ink);
	margin-bottom: 30px;
}
.read-also__grid {
	display: grid;
	grid-template-columns: repeat(2, 1fr);
	gap: 44px;
}
.card--related .card__title { font-size: 1.5rem; }

/* =========================================================
   8. Archive / index / search
   ========================================================= */
.archive-page { padding-top: 44px; }
.page-heading {
	max-width: var(--maxw);
	margin: 0 auto 8px;
	padding: 0 var(--gutter);
}
.page-heading .rule-top { margin-bottom: 22px; }
.section-title {
	font-family: var(--serif);
	font-weight: 500;
	font-size: clamp(2rem, 4vw, 3rem);
	line-height: 1.05;
	color: var(--ink);
}
.page-heading .eyebrow { display: block; margin-bottom: 8px; }

.pagination {
	max-width: var(--maxw);
	margin: 60px auto 0;
	padding: 0 var(--gutter);
}
.pagination .nav-links {
	display: flex;
	justify-content: center;
	gap: 8px;
	flex-wrap: wrap;
}
.pagination a, .pagination .current {
	display: inline-flex;
	min-width: 42px;
	height: 42px;
	align-items: center;
	justify-content: center;
	padding: 0 10px;
	border: 1px solid var(--line);
	font-size: 15px;
	text-decoration: none;
}
.pagination .current { background: var(--black); color: #fff; border-color: var(--black); }
.pagination a:hover { border-color: var(--ink); text-decoration: none; }

.no-results {
	max-width: var(--wrap);
	margin: 0 auto;
	padding: 20px var(--gutter) 0;
}

/* =========================================================
   9. Comments
   ========================================================= */
.comments-area {
	max-width: var(--wrap);
	margin: 64px auto 0;
	padding: 0 var(--gutter);
}
.comments-title, .comment-reply-title {
	font-family: var(--serif);
	font-weight: 500;
	font-size: 1.6rem;
	margin-bottom: 24px;
	color: var(--ink);
}
.comment-list { list-style: none; margin: 0; padding: 0; }
.comment-list li { margin: 0 0 24px; }
.comment-list .children { list-style: none; margin: 20px 0 0 28px; padding: 0; }
.comment-body { border-bottom: 1px solid var(--line); padding-bottom: 20px; }
.comment-author { font-weight: 600; color: var(--ink); }
.comment-meta { font-size: 12px; color: var(--muted); margin-bottom: 8px; }
.comment-respond { margin-top: 32px; }
.comment-form label { display: block; font-size: 13px; font-weight: 600; margin: 14px 0 6px; }
.comment-form input[type="text"],
.comment-form input[type="email"],
.comment-form input[type="url"],
.comment-form textarea {
	width: 100%;
	border: 1px solid #d8d6d3;
	border-radius: 3px;
	padding: 11px 13px;
	font: inherit;
	font-size: 15px;
}
.comment-form .submit,
.form-submit input {
	background: var(--black);
	color: #fff;
	border: 0;
	border-radius: 3px;
	padding: 12px 26px;
	font: inherit;
	font-size: 14px;
	cursor: pointer;
	margin-top: 16px;
}

/* =========================================================
   10. Footer
   ========================================================= */
.site-footer {
	background: var(--black);
	color: #fff;
	margin-top: 96px;
	padding: 58px 0;
}
.site-footer__inner {
	display: flex;
	justify-content: space-between;
	align-items: flex-end;
	gap: 40px;
	flex-wrap: wrap;
}
.site-footer__brand,
.site-footer__brand:hover {
	font-family: var(--serif);
	font-weight: 500;
	font-size: clamp(2rem, 3.6vw, 2.85rem);
	letter-spacing: 0.15em;
	text-transform: uppercase;
	color: #fff;
	text-decoration: none;
	padding-left: 0.15em;
}
.site-footer__meta { text-align: right; }
.footer-menu {
	list-style: none;
	margin: 0 0 14px;
	padding: 0;
	display: flex;
	flex-wrap: wrap;
	justify-content: flex-end;
	gap: 24px;
	font-size: 13px;
}
.footer-menu a { color: #cbc9c6; text-decoration: none; }
.footer-menu a:hover { color: #fff; text-decoration: underline; text-underline-offset: 3px; }
.site-footer__copy { margin: 0; color: #86847f; font-size: 13px; }

/* =========================================================
   11. Responsive
   ========================================================= */
@media (max-width: 1080px) {
	.home-hero {
		grid-template-columns: 1fr 1fr;
		gap: 40px;
	}
	.home-hero__main { grid-column: 1 / -1; order: -1; }
	.mr-item__media { aspect-ratio: 16 / 9; }
}

@media (max-width: 860px) {
	body { font-size: 16px; }
	.site-header__inner {
		grid-template-columns: auto 1fr auto;
		gap: 14px;
		padding: 18px 0 16px;
	}
	.site-header__left { order: 3; grid-column: 1 / -1; justify-self: stretch; }
	.search-form { max-width: none; }
	.site-header__brand { justify-self: start; }
	.brand-word { font-size: 1.7rem; letter-spacing: 0.12em; }
	.btn-subscribe { padding: 10px 18px; }

	/* Collapsible nav */
	.site-nav__inner { justify-content: flex-start; }
	.nav-toggle { display: inline-flex; }
	.nav-menu {
		display: none;
		flex-direction: column;
		align-items: flex-start;
		gap: 4px;
		width: 100%;
		margin-top: 12px;
	}
	.nav-menu.is-open { display: flex; }
	.nav-menu a { display: block; padding: 8px 0; font-size: 16px; }

	.home-hero { grid-template-columns: 1fr; gap: 8px; padding-top: 30px; }
	.home-hero__main { order: 0; }
	.home-hero__aside,
	.home-hero__side { margin-top: 34px; }

	.cards-grid { grid-template-columns: 1fr; gap: 40px; }
	.read-also__grid { grid-template-columns: 1fr; gap: 36px; }

	.section { margin-top: 54px; }
	.section__head { flex-direction: row; }

	.article-head .rule-top { margin: 28px 0 18px; }
	.article-body { font-size: 1.05rem; }
	.article-body p:first-of-type { font-size: 1.12rem; }

	.site-footer { margin-top: 64px; padding: 44px 0; }
	.site-footer__inner { align-items: flex-start; }
	.site-footer__meta { text-align: left; }
	.footer-menu { justify-content: flex-start; }
}

@media (max-width: 520px) {
	.mini__media { flex-basis: 56px; width: 56px; height: 56px; }
	.mini__title { font-size: 1.16rem; }
	.article-title { max-width: none; }
}

@media (prefers-reduced-motion: reduce) {
	* { animation: none !important; transition: none !important; }
	.card:hover .card__media img { transform: none; }
}
