/* Kannur Tourism. Colours come from Theyyam (vermilion, turmeric) and the sea;
   the striped band is drawn from Kannur handloom cloth. */

@font-face { font-family: "Anek Latin"; src: url(../fonts/anek-latin.woff2) format("woff2"); font-weight: 400 800; font-stretch: 75% 125%; font-display: swap; }
@font-face { font-family: "Anek Latin"; src: url(../fonts/anek-latin-ext.woff2) format("woff2"); font-weight: 400 800; font-stretch: 75% 125%; font-display: swap; unicode-range: U+0100-02BA, U+1E00-1E9F, U+20A0-20AB, U+20AD-20C4; }
@font-face { font-family: "Anek Malayalam"; src: url(../fonts/anek-malayalam-kannur.woff2) format("woff2"); font-weight: 700; font-display: swap; } /* only the letters of കണ്ണൂർ */

:root {
  --ink: #14292d;
  --muted: #51666a;
  --sea: #0b3a40;
  --lagoon: #0c6d6b;
  --vermilion: #c92a1a;
  --turmeric: #f5ae1b;
  --mist: #edf4f3;
  --line: #d3dfde;
  --white: #fff;
  --radius: 6px;
  --gap: clamp(18px, 2.4vw, 32px);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--white); color: var(--ink); font: 400 1.125rem/1.6 "Anek Latin", system-ui, sans-serif; }
img { display: block; max-width: 100%; height: auto; }
h1, h2, h3 { margin: 0; line-height: 1.12; font-weight: 700; text-wrap: balance; }
h1 { font-size: clamp(2.1rem, 1.5rem + 2.6vw, 3.5rem); font-stretch: 112%; letter-spacing: -.015em; }
h2 { font-size: clamp(1.55rem, 1.3rem + 1vw, 2.1rem); font-stretch: 108%; letter-spacing: -.01em; }
h3 { font-size: 1.3rem; line-height: 1.2; }
p { margin: 0 0 1em; }
ul { margin: 0; padding: 0; list-style: none; }
a { color: var(--lagoon); text-underline-offset: .18em; text-decoration-thickness: 1px; }
a:hover { color: var(--vermilion); }
:focus-visible { outline: 3px solid var(--turmeric); outline-offset: 2px; border-radius: 3px; }
.wrap { width: min(1200px, 100% - 2 * clamp(16px, 4vw, 40px)); margin-inline: auto; }
.visually-hidden, .skip:not(:focus) { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.skip:focus { position: absolute; z-index: 50; left: 12px; top: 12px; padding: 8px 16px; background: var(--white); }

.weave { height: 8px; background: repeating-linear-gradient(90deg,
  var(--vermilion) 0 34px, var(--turmeric) 34px 42px, var(--vermilion) 42px 48px, var(--white) 48px 51px, var(--sea) 51px 77px,
  var(--white) 77px 80px, #1b8a86 80px 104px, var(--turmeric) 104px 108px, #1b8a86 108px 116px, var(--sea) 116px 124px); }

/* ---------- Header and menu ---------- */
.site-header { position: sticky; top: 0; z-index: 20; background: var(--white); border-bottom: 1px solid var(--line); }
.bar { display: flex; align-items: center; justify-content: space-between; gap: 24px; min-height: 66px; position: relative; }
.brand { display: flex; align-items: center; gap: 11px; font-size: 1.35rem; font-weight: 700; font-stretch: 108%; color: var(--ink); text-decoration: none; white-space: nowrap; }
.brand img { width: 44px; height: 44px; }
.menu a { color: var(--ink); text-decoration: none; }
.menu a:hover { color: var(--vermilion); }
.menu > ul > li > a { font-weight: 500; }
.drop-button { border: 0; background: none; color: inherit; cursor: pointer; padding: 0; }
.drop-button::before { content: ""; display: block; width: 8px; height: 8px; margin: auto; border: solid currentColor; border-width: 0 2px 2px 0; transform: translateY(-2px) rotate(45deg); }
.drop-button[aria-expanded=true]::before { transform: translateY(2px) rotate(225deg); }
.menu .drop-title a { color: var(--lagoon); }
.drop-title { margin: 0 0 6px; font-weight: 700; color: var(--lagoon); font-size: 1rem; }
.drop li a { display: block; padding: 4px 0; font-size: 1.02rem; line-height: 1.35; }
.drop-all { display: inline-block; margin-top: 14px; font-weight: 600; }
.menu .drop-all { color: var(--lagoon); text-decoration: underline; }

@media (min-width: 900px) {
  .menu-button { display: none; }
  .menu > ul { display: flex; align-items: stretch; gap: clamp(14px, 1.9vw, 28px); }
  .menu > ul > li { display: flex; align-items: center; }
  .menu > ul > li > a { display: flex; align-items: center; height: 66px; border-block: 3px solid transparent; }
  .menu a[aria-current] { border-bottom-color: var(--vermilion); }
  .drop-button { width: 24px; height: 40px; margin-right: -6px; }
  .drop { position: absolute; top: 100%; right: 0; visibility: hidden; opacity: 0; padding: 26px 30px 24px; background: var(--white); border: 1px solid var(--line); border-radius: 0 0 var(--radius) var(--radius); box-shadow: 0 18px 40px rgb(11 58 64 / .16); transition: opacity .15s, visibility .15s; max-height: calc(100vh - 90px); overflow: auto; }
  .has-drop:hover .drop, .has-drop.open .drop { visibility: visible; opacity: 1; }
  .has-drop.closed .drop { visibility: hidden; opacity: 0; }
  .drop-columns { display: grid; grid-template-columns: repeat(4, minmax(170px, 215px)); gap: 28px; }
  .drop-photos ul { columns: 2; column-gap: 34px; width: 480px; }
  .drop-photos li { break-inside: avoid; }
}
@media (max-width: 899px) {
  .menu-button { border: 1px solid var(--line); border-radius: var(--radius); background: var(--white); color: var(--ink); font: 600 1rem/1 inherit; font-family: inherit; padding: 12px 16px; cursor: pointer; }
  .menu { display: none; position: absolute; top: 100%; left: calc(-1 * clamp(16px, 4vw, 40px)); right: calc(-1 * clamp(16px, 4vw, 40px)); padding: 6px clamp(16px, 4vw, 40px) 24px; background: var(--white); border-bottom: 1px solid var(--line); box-shadow: 0 18px 30px rgb(11 58 64 / .16); max-height: calc(100vh - 76px); max-height: calc(100dvh - 76px); overflow: auto; }
  .menu.open { display: block; }
  .menu > ul > li { display: grid; grid-template-columns: 1fr auto; border-bottom: 1px solid var(--line); }
  .menu > ul > li > a { padding: 11px 0; font-size: 1.15rem; }
  .menu a[aria-current] { color: var(--vermilion); }
  .drop-button { width: 52px; border-left: 1px solid var(--line); }
  .drop { display: none; grid-column: 1 / -1; padding: 4px 0 18px 14px; }
  .open > .drop { display: block; }
  .drop-columns { display: grid; gap: 16px; }
  .drop li a { padding: 8px 0; }
}

/* ---------- Home ---------- */
.hero { background: var(--sea); color: var(--white); }
.hero-grid { display: grid; gap: clamp(28px, 4vw, 64px); padding-block: clamp(36px, 5vw, 72px); align-items: center; }
.hero-malayalam { margin: 0 0 6px; font: 700 clamp(3.4rem, 2rem + 6vw, 6.5rem)/1.25 "Anek Malayalam", "Nirmala UI", sans-serif; color: var(--turmeric); }
.hero h1 { font-size: clamp(2rem, 1.4rem + 2.3vw, 3.2rem); }
.hero-lead { max-width: 34em; margin: 18px 0 28px; font-size: 1.25rem; line-height: 1.5; color: #d5e6e4; }
.hero-images { display: grid; grid-template-columns: 1.15fr 1fr; grid-template-rows: 1fr 1fr; gap: 10px; aspect-ratio: 5 / 4; }
.hero-images a { overflow: hidden; border-radius: var(--radius); min-height: 0; }
.hero-images a:first-child { grid-row: 1 / 3; }
.hero-images img { width: 100%; height: 100%; object-fit: cover; }
.hero-images a:first-child img { object-position: 42% 50%; }
@media (min-width: 900px) { .hero-grid { grid-template-columns: 1fr 1.08fr; } }

.actions { display: flex; flex-wrap: wrap; gap: 12px; margin: 0; }
.button { display: inline-block; border: 2px solid var(--vermilion); border-radius: var(--radius); background: var(--vermilion); color: var(--white); padding: 12px 22px 10px; font: 600 1.1rem/1.3 "Anek Latin", sans-serif; text-decoration: none; cursor: pointer; transition: background .15s, border-color .15s; }
.button:hover { background: #a91f11; border-color: #a91f11; color: var(--white); }
.button-quiet { background: transparent; border-color: #7fa6a6; }
.button-quiet:hover { background: var(--white); border-color: var(--white); color: var(--sea); }

.section { padding-block: clamp(44px, 5.5vw, 80px); }
.section-tight { padding-bottom: clamp(48px, 6vw, 88px); }
.section-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 6px 24px; margin-bottom: 26px; }
.band { background: var(--mist); }
.about-home { display: grid; gap: 18px var(--gap); }
@media (min-width: 900px) { .about-home { grid-template-columns: 1fr 2fr; } }

/* ---------- Cards ---------- */
.cards { display: grid; gap: calc(var(--gap) * 1.4) var(--gap); grid-template-columns: repeat(auto-fill, minmax(min(290px, 100%), 1fr)); }
.card-image { display: block; overflow: hidden; border-radius: var(--radius); background: var(--mist); aspect-ratio: 4 / 3; }
.card-image img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s; }
.card:hover .card-image img, .album:hover img { transform: scale(1.04); }
.card-text { padding-top: 14px; }
.card-text p { margin: 0; }
.card h3 a { color: var(--ink); text-decoration: none; }
.card h3 a:hover { color: var(--vermilion); text-decoration: underline; }
.meta { display: flex; flex-wrap: wrap; gap: 0 10px; color: var(--muted); font-size: 1rem; }
.meta > :not(:last-child)::after { content: "/"; display: inline-block; margin-left: 10px; color: #a6b8b7; }
.card .meta { margin: 4px 0 8px; }
@media (min-width: 900px) {
  .newest { display: grid; grid-template-columns: 1.1fr 1fr; gap: var(--gap) calc(var(--gap) * 1.4); }
  .newest .card:first-child { grid-row: 1 / 3; }
  .newest .card:first-child h3 { font-size: 1.8rem; }
  .newest .card:not(:first-child) { display: grid; grid-template-columns: 1fr 1.05fr; gap: 24px; }
  .newest .card:not(:first-child) .card-image { aspect-ratio: auto; min-height: 200px; position: relative; }
  .newest .card:not(:first-child) .card-image img { position: absolute; inset: 0; }
  .newest .card:not(:first-child) .card-text { padding-top: 0; }
}
@media (max-width: 899px) { .newest { display: grid; gap: 32px; } }

.albums { display: grid; gap: clamp(10px, 1.6vw, 20px); grid-template-columns: repeat(auto-fill, minmax(min(250px, 46%), 1fr)); }
.album { position: relative; display: block; overflow: hidden; border-radius: var(--radius); aspect-ratio: 1; background: var(--sea); color: var(--white); text-decoration: none; }
.album:hover { color: var(--white); }
.album img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s; }
.album-text { position: absolute; inset: auto 0 0; padding: 60px 16px 12px; background: linear-gradient(transparent, rgb(6 30 33 / .88)); line-height: 1.25; }
.album-text strong { display: block; font-size: 1.22rem; }

/* ---------- Inner pages ---------- */
.page-head { padding-block: clamp(32px, 4.5vw, 60px) clamp(20px, 2.4vw, 32px); }
.page-head p { margin: 10px 0 0; }
.crumbs { margin: 0 0 8px; font-size: 1rem; }
.crumbs ol { display: flex; flex-wrap: wrap; gap: 0 10px; margin: 0; padding: 0; list-style: none; }
.crumbs li + li::before { content: "/"; margin-right: 10px; color: #a6b8b7; }
.topics { display: flex; flex-wrap: wrap; gap: 4px 22px; margin-top: 14px; }
.answer { margin-bottom: 22px; font-weight: 500; line-height: 1.5; }
.lead { max-width: 44em; font-size: 1.2rem; }
.list-bar { display: flex; margin-top: 16px; }
.switch { display: flex; border: 1px solid var(--lagoon); border-radius: var(--radius); overflow: hidden; }
.switch a { padding: 8px 16px 6px; text-decoration: none; font-weight: 500; }
.switch a[aria-current] { background: var(--lagoon); color: var(--white); }
.pager { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin-top: 52px; }
.pager a { min-width: 46px; padding: 9px 14px 7px; text-align: center; border: 1px solid var(--line); border-radius: var(--radius); text-decoration: none; font-weight: 500; }
.pager a:hover { border-color: var(--vermilion); }
.pager a[aria-current] { background: var(--lagoon); border-color: var(--lagoon); color: var(--white); }

.prose { max-width: 42em; }
.prose > :last-child { margin-bottom: 0; }
.prose h2 { margin: 1.6em 0 .6em; }
.prose > h2:first-child { margin-top: 0; }
.prose figure { margin: 1.8em 0; }
.prose img { border-radius: var(--radius); }
.prose figcaption { margin-top: 8px; color: var(--muted); font-size: 1rem; }
.prose:has(> table.wide) { max-width: 60em; }
table { width: 100%; border-collapse: collapse; line-height: 1.4; }
th, td { padding: 11px 14px 9px 0; text-align: left; vertical-align: top; border-bottom: 1px solid var(--line); }
th[scope=row] { width: 42%; font-weight: 500; color: var(--muted); }
thead th { border-bottom: 2px solid var(--ink); }
td.num { white-space: nowrap; }
.hotels { table-layout: fixed; }
.hotels th:last-child, .hotels td:last-child { width: 10.5em; }
.hotels a { white-space: nowrap; }
@media (max-width: 699px) {
  .hotels { display: block; }
  .hotels thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
  .hotels tbody { display: block; border-top: 2px solid var(--ink); }
  .hotels tr { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 0 14px; padding: 11px 0 9px; border-bottom: 1px solid var(--line); }
  .hotels td { padding: 0; border: 0; }
  .hotels td:first-child { font-weight: 600; }
  .hotels td:nth-child(2) { grid-row: 2; color: var(--muted); font-size: 1rem; }
  .hotels td:last-child { grid-column: 2; grid-row: 1 / 3; width: auto; line-height: 1.7; text-align: right; }
}
.num { text-align: right; padding-right: 0; font-variant-numeric: tabular-nums; }
.prose ul { list-style: disc; padding-left: 1.2em; margin-bottom: 1em; }
.prose li { margin-bottom: .4em; }
.table-scroll { overflow-x: auto; margin-top: 20px; }
.faqs { display: grid; gap: 22px var(--gap); }
.faq-list { display: grid; gap: 26px; max-width: 46em; }
.faq-list h3 { margin-bottom: 6px; }
.faq-list p { margin: 0; }
@media (min-width: 900px) { .faqs { grid-template-columns: 1fr 2fr; } }
.map { display: block; width: 100%; aspect-ratio: 4 / 3; border: 0; border-radius: var(--radius); background: var(--mist); margin-bottom: 10px; }

.place { display: grid; gap: 0 clamp(32px, 4.5vw, 64px); padding-block: clamp(28px, 4vw, 52px) clamp(44px, 5.5vw, 80px); }
.place-head .meta { margin: 10px 0 24px; }
.place-image img { width: 100%; border-radius: var(--radius); margin-bottom: 28px; max-height: 620px; object-fit: cover; }
.place-side { margin-top: 36px; display: grid; gap: 28px; align-content: start; }
.facts { border-top: 8px solid var(--turmeric); background: var(--mist); padding: 20px 22px 10px; border-radius: 0 0 var(--radius) var(--radius); }
.facts h2 { font-size: 1.4rem; margin-bottom: 8px; }
.facts dl { margin: 0; }
.facts dl div { padding: 9px 0; border-top: 1px solid var(--line); }
.facts dl div:first-child { border-top: 0; }
.facts dt { color: var(--muted); font-size: 1rem; line-height: 1.3; }
.facts dd { margin: 0; font-weight: 500; line-height: 1.4; }
@media (min-width: 900px) {
  .place { grid-template-columns: minmax(0, 1fr) 350px; }
  .place-head { grid-column: 1 / -1; }
  .place-side { margin-top: 0; }
}

/* ---------- Photos ---------- */
.wall { display: flex; flex-wrap: wrap; gap: 10px; }
.wall a { flex: var(--ratio) 1 calc(var(--ratio) * 210px); max-width: calc(var(--ratio) * 400px); border-radius: var(--radius); overflow: hidden; background: var(--mist); }
.wall img { width: 100%; height: 100%; object-fit: cover; transition: opacity .2s; }
.wall a:hover img { opacity: .86; }
@media (max-width: 560px) { .wall a { flex-basis: calc(var(--ratio) * 120px); } }

.viewer { width: 100vw; height: 100vh; height: 100dvh; max-width: none; max-height: none; margin: 0; padding: 0; border: 0; background: rgb(5 22 25 / .96); color: var(--white); }
.viewer[open] { display: grid; grid-template-rows: minmax(0, 1fr) auto; }
.viewer img { width: 100%; height: 100%; object-fit: scale-down; padding: 64px 16px 8px; }
.viewer-bar { display: flex; align-items: center; justify-content: center; gap: 18px; padding: 12px 16px 20px; }
.viewer-bar p { margin: 0; flex: 0 1 34em; min-height: 2.6em; display: grid; place-items: center; text-align: center; line-height: 1.3; }
@media (max-width: 699px) {
  .viewer-bar { flex-wrap: wrap; }
  .viewer-bar p { order: -1; flex-basis: 100%; }
}
.viewer button { border: 1px solid #6d9092; border-radius: var(--radius); background: transparent; color: inherit; font: 500 1rem/1 "Anek Latin", sans-serif; padding: 13px 18px 11px; cursor: pointer; }
.viewer button:hover { background: var(--white); color: var(--sea); }
.viewer-close { position: absolute; top: 12px; right: 16px; }

/* ---------- Contact form ---------- */
.form, .notice { max-width: 38em; margin-top: 28px; }
.field { margin-bottom: 18px; }
.field label { display: block; margin-bottom: 4px; font-weight: 600; }
.field input, .field textarea { width: 100%; padding: 11px 13px 9px; border: 1px solid #8aa09f; border-radius: var(--radius); background: var(--white); color: inherit; font: inherit; }
.field textarea { resize: vertical; }
.field [aria-invalid] { border-color: var(--vermilion); border-width: 2px; }
.error { margin: 4px 0 0; color: var(--vermilion); }
.trap { position: absolute; left: -9999px; }
.notice { padding: 14px 18px 12px; border-left: 6px solid; background: var(--mist); }
.notice-good { border-color: var(--lagoon); }
.notice-bad { border-color: var(--vermilion); }

/* ---------- Footer ---------- */
.site-footer { background: var(--sea); color: #d5e6e4; }
.footer-grid { display: grid; gap: 24px 48px; padding-block: 40px 32px; }
.footer-grid p { margin: 0; }
.footer-brand { display: flex; align-items: center; gap: 16px; }
.footer-name { font-size: 1.35rem; font-weight: 700; color: var(--white); }
.site-footer a { color: inherit; }
.site-footer a:hover { color: var(--turmeric); }
.site-footer li a { display: inline-block; padding: 3px 0; }
.footer-credit { font-size: 1rem; }
@media (min-width: 700px) { .footer-grid { grid-template-columns: 2fr 1fr 1fr; } .footer-credit { grid-column: 1 / -1; } }

@media (prefers-reduced-motion: reduce) { *, *::before, *::after { transition: none !important; scroll-behavior: auto !important; } }
@media print { .site-header, .site-footer, .map, .band { display: none; } }
