/*
Theme Name: Direct Iceland
Description: A travel editorial theme for Direct Iceland.
Version: 1.1.1
Requires at least: 6.0
Requires PHP: 7.4
Text Domain: direct-iceland
*/

:root {
    --paper: #f8f6ee;
    --ink: #182924;
    --pine: #21483d;
    --gold: #e7d987;
    --map-blue: #e4eff5;
    --line: #d7d9cb;
    --display: Georgia, "Times New Roman", serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-padding-top: 1rem; }
body { margin: 0; color: var(--ink); background: var(--paper); font: 1rem/1.6 system-ui, sans-serif; }
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid #af592b; outline-offset: 4px; }
h1, h2 { font-family: var(--display); line-height: 1.02; font-weight: 400; letter-spacing: -.045em; }
h1 { font-size: clamp(2.8rem, 7vw, 6rem); margin: 0 0 1.25rem; }
h2 { font-size: clamp(2.35rem, 5vw, 4.2rem); margin: 0; }
input, textarea, button { max-width: 100%; font: inherit; }
.shell { width: min(89%, 80rem); margin-inline: auto; }
.section { padding-block: clamp(3rem, 7vw, 6.25rem); }
.skip-link { position: absolute; top: .5rem; left: .5rem; z-index: 5; transform: translateY(-200%); background: white; padding: .5rem 1rem; }
.skip-link:focus { transform: translateY(0); }

.masthead { background: #fff; position: relative; z-index: 2; }
.masthead-inner, .footer-inner { min-height: 5.4rem; display: flex; align-items: center; justify-content: space-between; gap: 1rem 2rem; }
.brand img, .custom-logo { width: clamp(7rem, 13vw, 10rem); height: auto; }
.masthead nav ul { margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: .4rem clamp(.9rem, 3vw, 2.4rem); list-style: none; }
.masthead nav a, .text-link { font-weight: 650; text-underline-offset: .24em; }
.masthead nav a:not(:hover):not([aria-current]) { text-decoration: none; }
.masthead .menu-item-has-children { position: relative; }
.masthead nav .sub-menu { display: none; position: absolute; min-width: 12rem; padding: .8rem; background: white; box-shadow: 0 .5rem 1.5rem #18292422; }
.masthead li:hover > .sub-menu, .masthead li:focus-within > .sub-menu { display: grid; }
.button { display: inline-flex; gap: .75rem; align-items: center; justify-content: center; width: fit-content; border: 1px solid transparent; border-radius: 99rem; padding: .75rem 1.25rem; background: var(--pine); color: white; text-decoration: none; font-weight: 650; }
.button:hover { text-decoration: underline; text-underline-offset: .2em; }
.button.light { background: var(--gold); color: var(--ink); }
.button.outline { border-color: #fffd; background: #13272165; }
.button.small { padding: .55rem 1rem; white-space: nowrap; font-size: .9rem; }

.hero { position: relative; isolation: isolate; display: grid; align-items: end; min-height: clamp(32rem, 72svh, 50rem); background: #304e3f; color: white; }
.hero::after, .hero-photo { position: absolute; inset: 0; width: 100%; height: 100%; }
.hero-photo { z-index: -2; object-fit: cover; object-position: center 55%; }
.hero::after { content: ""; z-index: -1; background: linear-gradient(90deg, #10231ed9, #172a2366 60%, transparent), linear-gradient(0deg, #10231ea5, transparent 60%); }
.hero-inner { padding-block: 5rem clamp(3rem, 9vw, 7rem); }
.hero h1 { font-size: clamp(3.8rem, 10vw, 8.2rem); line-height: .89; }
.hero p { max-width: 32rem; font-size: clamp(1rem, 2vw, 1.25rem); margin-block: 1.5rem; }
.actions { display: flex; gap: .65rem; flex-wrap: wrap; }
.section-heading { display: flex; align-items: end; justify-content: space-between; flex-wrap: wrap; gap: .8rem 2rem; margin-bottom: 1.75rem; }
.regions, .guide-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: clamp(.8rem, 2vw, 1.5rem); }
.region { position: relative; display: grid; align-items: end; isolation: isolate; min-height: 16rem; aspect-ratio: 4/5; overflow: hidden; border-radius: .65rem; color: white; background: var(--pine); text-decoration: none; }
.region img, .region::after { position: absolute; inset: 0; width: 100%; height: 100%; }
.region img { object-fit: cover; z-index: -2; transition: transform .25s; }
.region::after { content: ""; background: linear-gradient(transparent 42%, #101c16ed); z-index: -1; }
.region:hover img { transform: scale(1.05); }
.region > span { display: flex; align-items: center; justify-content: space-between; gap: .4rem; padding: 1rem; font: clamp(1.05rem, 2vw, 1.55rem)/1.1 var(--display); }
.feature { display: grid; grid-template-columns: 1.2fr 1fr; align-items: center; gap: 2rem clamp(2rem, 6vw, 6rem); border-top: 1px solid var(--line); }
.feature img { width: 100%; border-radius: .65rem; background: var(--map-blue); padding: clamp(.65rem, 2.5vw, 2rem); }
.feature p { max-width: 34ch; }
.travel-map { padding-top: 2rem; }
.map-links { display: grid; gap: .5rem; padding: 0; list-style: none; }
.map-links a { display: flex; justify-content: space-between; gap: .5rem; padding: .65rem 0; border-bottom: 1px solid var(--line); text-underline-offset: .2em; }
.region-banner { width: 100%; max-height: 26rem; object-fit: cover; border-radius: .65rem; }
.region-banner--north { object-position: center top; }
.region-intro { margin-block: 1.75rem 2.5rem; font-size: clamp(1.08rem, 2vw, 1.25rem); }
.trip-starters { padding-top: 0; }
.trip-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; margin-top: 1.5rem; }
.trip-card { overflow: hidden; display: flex; flex-direction: column; border: 1px solid var(--line); border-radius: .8rem; background: white; }
.trip-card img { width: 100%; aspect-ratio: 16/9; object-fit: cover; }
.trip-card-copy { display: flex; flex: 1; flex-direction: column; padding: clamp(1rem, 2.5vw, 1.75rem); }
.trip-card h3 { font: clamp(1.55rem, 2.6vw, 2rem)/1.1 var(--display); margin: 0; }
.trip-card p { margin-block: .65rem 1.15rem; }
.trip-card ul { display: grid; gap: .45rem; list-style: none; margin: auto 0 0; padding: 0; }
.trip-card a { display: flex; gap: .5rem; justify-content: space-between; border-top: 1px solid var(--line); padding-top: .45rem; color: var(--pine); font-weight: 650; text-underline-offset: .2em; }
.guide-search, .guide-filters { display: flex; flex-wrap: wrap; gap: .65rem 1rem; }
.guide-search { align-items: end; margin-bottom: 1rem; padding: clamp(.8rem, 2.5vw, 1.4rem); background: #eef0e7; border-radius: .65rem; }
.guide-search label { flex: 1; max-width: 26rem; }
.guide-search label, .contact-form label { display: grid; gap: .25rem; font-weight: 650; }
.guide-search input, .contact-form input, .contact-form textarea { width: 100%; min-width: 0; padding: .6rem .8rem; border: 1px solid var(--pine); border-radius: .35rem; background: #fff; color: var(--ink); font-weight: 400; }
.guide-filters a { padding: .45rem .85rem; border: 1px solid var(--line); border-radius: 99rem; background: white; color: var(--pine); font-weight: 650; text-underline-offset: .2em; }
.contact-form { display: grid; gap: 1rem; max-width: 38rem; }
.contact-form .button, .guide-search .button { cursor: pointer; }
.form-feedback { padding: .75rem 1rem; border-left: .25rem solid var(--pine); background: white; }
@media (max-width: 760px) { .trip-grid { grid-template-columns: 1fr; } }
.adventures { background: var(--pine); color: white; }
.adventure-inner { display: flex; align-items: end; justify-content: space-between; flex-wrap: wrap; gap: 1rem 3rem; padding-block: clamp(2.8rem, 6vw, 5rem); }
.adventure-inner p:last-child { margin-bottom: 0; }
.kicker { color: var(--gold); font-weight: 700; margin: 0 0 .7rem; }
.guide-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); margin-block: 1.5rem; }
.guide-card { background: white; border: 1px solid var(--line); border-radius: .65rem; overflow: hidden; min-width: 0; overflow-wrap: anywhere; }
.guide-card img { width: 100%; aspect-ratio: 16/10; object-fit: cover; }
.card-copy { padding: 1.35rem; }
.card-copy h2 { font-size: clamp(1.45rem, 3vw, 2.4rem); }
.card-copy h2 a { text-decoration-thickness: 1px; text-underline-offset: .15em; }
.card-copy p:last-child { margin-bottom: 0; }
.prose { max-width: 51rem; margin-inline: auto; overflow-wrap: anywhere; }
.prose h1 { font-size: clamp(2.6rem, 6.5vw, 5rem); }
.prose h2 { margin-block: 1.35em .4em; font-size: clamp(1.8rem, 4vw, 3rem); }
.prose iframe { max-width: 100%; }
.article-photo { border-radius: .65rem; margin-bottom: 2rem; }
.site-footer { border-top: 1px solid var(--line); background: #fff; }
.footer-inner { padding-block: 1.4rem; flex-wrap: wrap; }
.footer-inner nav { display: flex; gap: .5rem 1.3rem; flex-wrap: wrap; }

@media (max-width: 760px) {
    .masthead-inner { flex-wrap: wrap; padding-block: .75rem; }
    .masthead nav { order: 1; width: 100%; }
    .regions, .guide-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .region { min-height: 12rem; }
    .feature { grid-template-columns: 1fr; }
}
@media (max-width: 470px) {
    .guide-grid { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) {
    .region img { transition: none; }
}
