/* ============================================================================
   Contact page.

   The number is the headline: it is the same for calls and WhatsApp, and it
   is what a guest came here for. Beside it, a composer that writes the
   WhatsApp message; below, a card to hand a rickshaw driver, and the way in
   from the station, the airport and the fort. Loaded after home.css and
   borrows from it -- the .ask__f fields, the arch, the .where band and its
   map -- rather than restyling.
   ========================================================================== */

/* The driver card's Devanagari. Tiro Devanagari Hindi (SIL OFL), cut down by
   build/bin/deva-font to the letters of MM_NAME_HI and MM_ADDR_HI -- about
   13 KB, and only this page asks for it. A traditional serif, so it sits
   beside Fraunces rather than against it. */
@font-face {
	font-family: 'Tiro Devanagari Hindi';
	src: url('../fonts/tiro-devanagari-hi.woff2') format('woff2');
	font-weight: 400;
	font-display: swap;
	unicode-range: U+0900-097F, U+200C-200D, U+0020, U+002C, U+002E, U+25CC;
}

/* Every section here carries its own call and WhatsApp buttons, so the
   floating pair would only ever be the second copy on screen. */
.fabs { display: none; }

/* The gold rule under a section heading, as the homepage hangs it. */
.chero__say h1::after,
.driver__say h2::after {
	content: ''; display: block; width: 58px; height: 2px;
	background: var(--gold); margin: .7rem 0 1.15rem;
}

/* ── The number ───────────────────────────────────────────────────────────── */
.chero { padding-block: clamp(2.2rem, 4.5vw, 4rem) clamp(3.5rem, 6.5vw, 5.5rem); }
.chero__in {
	display: grid; grid-template-columns: 1fr 1.05fr;
	gap: clamp(2rem, 5vw, 4.5rem); align-items: start;
}
/* Smaller than the homepage h1, on purpose: the number below is the thing
   set largest on this page. */
.chero__say h1 { font-size: var(--t-2xl); margin-bottom: 0; }

/* Set as display type, lining and tabular so the groups read as a number
   rather than as a word. The country code steps back: guests calling from
   inside India dial the ten digits. */
.cnum { margin: 1.9rem 0 0; max-width: none; line-height: 1; }
.cnum a {
	display: inline-flex; align-items: baseline; gap: .28em;
	font-family: var(--disp); font-weight: 400;
	font-size: clamp(2.3rem, 4.6vw, 3.7rem);
	letter-spacing: -.015em;
	font-variant-numeric: lining-nums tabular-nums;
	font-variation-settings: 'opsz' 144, 'SOFT' 20;
	color: var(--ink); text-decoration: none; white-space: nowrap;
}
.cnum__cc {
	font-family: var(--ui); font-weight: 600; font-size: .4em;
	letter-spacing: 0; color: var(--ink-70);
}
.cnum a:hover { color: var(--brand-ink); }
.cnum a:hover .cnum__cc { color: var(--brand-ink); }

.chero__acts { display: flex; flex-wrap: wrap; gap: .8rem; margin-top: 1.6rem; }
.cmail { margin: 1rem 0 0; font-size: var(--t-sm); color: var(--ink-70); }

/* The front desk's hours, which is what a hotel has instead of opening
   times. The figures take the weight, as in the homepage .facts row. */
.ctimes {
	display: grid; grid-template-columns: repeat(3, auto); justify-content: start;
	gap: 1rem clamp(1.6rem, 3.5vw, 2.8rem);
	margin: 2.2rem 0 0; padding-top: 1.3rem;
	border-top: 1px solid var(--line-2);
}
.ctimes dt { font-size: var(--t-xs); color: var(--ink-70); line-height: 1.3; }
.ctimes dd {
	margin: .3rem 0 0;
	font-family: var(--disp); font-weight: 500; font-size: var(--t-lg); line-height: 1;
	color: var(--brand-ink); font-variant-numeric: lining-nums tabular-nums;
	font-variation-settings: 'opsz' 30, 'SOFT' 10;
}

.chero__rev {
	display: flex; flex-wrap: wrap; align-items: center; gap: .7rem 1.2rem;
	margin: 1.8rem 0 0; max-width: none; font-size: var(--t-sm);
}
.chero__rev > a:last-child { font-weight: 600; }

/* ── Composer ─────────────────────────────────────────────────────────────── */
/* The homepage enquiry strip, stood on end: paper, one hairline, the brand
   orange along the top. */
.compose {
	background: var(--paper);
	border: 1px solid var(--line);
	border-top: 2px solid var(--brand);
	padding: clamp(1.3rem, 2.6vw, 2.1rem);
}
.compose__h { font-size: var(--t-xl); margin: 0 0 1.2rem; }

.topics { border: 0; margin: 0 0 1.35rem; padding: 0; min-width: 0; }
.topics legend { padding: 0; margin-bottom: .6rem; font: 600 var(--t-xs)/1 var(--ui); color: var(--ink-70); }
.topics__row { display: flex; flex-wrap: wrap; gap: .4rem; }
/* The radios stay in the tab order; only their labels are drawn. */
.topics input {
	position: absolute; width: 1px; height: 1px; margin: 0;
	opacity: 0; pointer-events: none;
}
.topics label {
	font: 600 var(--t-sm)/1 var(--ui);
	padding: .72em 1.05em;
	color: var(--ink); background: var(--sand);
	border: 1px solid var(--line-2); border-radius: 2px 2px 0 0;
	cursor: pointer;
	transition: background-color .18s var(--ease), color .18s var(--ease), border-color .18s var(--ease);
}
.topics label:hover { border-color: var(--ink); }
.topics input:checked + label { background: var(--ink); border-color: var(--ink); color: var(--sand); }
.topics input:focus-visible + label { outline: 2.5px solid var(--brand-ink); outline-offset: 2px; }

/* One set of fields per topic. The radio decides which is shown -- in CSS,
   so it works with the script gone. contact.js mirrors the choice onto
   data-topic for browsers without :has(). Kept as separate rules: in one
   selector list, a browser that cannot parse :has() would drop the lot. */
.compose__set {
	display: none;
	grid-template-columns: 1fr 1fr; gap: .9rem;
	margin-bottom: .9rem;
}
.compose:has(#t-room:checked)   .compose__set--room,
.compose:has(#t-pickup:checked) .compose__set--pickup,
.compose:has(#t-safari:checked) .compose__set--safari { display: grid; }
.compose[data-topic="room"]   .compose__set--room,
.compose[data-topic="pickup"] .compose__set--pickup,
.compose[data-topic="safari"] .compose__set--safari { display: grid; }

/* The message box is the whole form for "Something else", and a note on
   the others. Its label says which. */
.compose__own { display: none; }
.compose:has(#t-other:checked) .compose__own { display: inline; }
.compose:has(#t-other:checked) .compose__add { display: none; }
.compose[data-topic="other"] .compose__own { display: inline; }
.compose[data-topic="other"] .compose__add { display: none; }

.compose .ask__f input,
.compose .ask__f select,
.compose .ask__f textarea { background-color: var(--sand); }
.ask__f textarea {
	font: 500 var(--t-sm)/1.5 var(--ui);
	color: var(--ink);
	padding: .7rem;
	border: 1px solid var(--line-2);
	border-radius: 2px;
	width: 100%; min-height: 5.4rem;
	resize: vertical;
}
.compose:has(#t-other:checked) textarea { min-height: 9rem; }
.compose[data-topic="other"] textarea { min-height: 9rem; }

.compose__go { width: 100%; justify-content: center; margin-top: 1.2rem; }
.compose__fine { margin: .8rem 0 0; font-size: var(--t-xs); color: var(--ink-70); text-align: center; max-width: none; }

/* ── For the driver ───────────────────────────────────────────────────────── */
.driver__in {
	display: grid; grid-template-columns: 1.3fr .7fr;
	gap: clamp(2rem, 5.5vw, 5rem); align-items: center;
}
.driver__say h2 { margin-bottom: 0; }
.driver__say > p { color: var(--ink-70); }

/* The one loud thing on the page. Indigo like the footer, with a gold
   hairline set in from the edge like the painted board over the door. It
   has to read at arm's length, in sun, to someone who reads Hindi first. */
.dboard {
	margin-top: 1.8rem;
	padding: clamp(1.7rem, 3.6vw, 2.8rem) clamp(1.5rem, 3.6vw, 3rem);
	background: var(--ink); color: var(--sand);
	outline: 1px solid rgba(217, 164, 65, .5); outline-offset: -10px;
}
.dboard p { margin: 0; max-width: none; }
/* The theme's own faces are Latin only. Behind the self-hosted cut, the
   Devanagari every phone this is likely to be shown on already carries. */
.dboard [lang="hi"] {
	font-family: 'Tiro Devanagari Hindi', 'Kohinoor Devanagari', 'Noto Sans Devanagari', 'Nirmala UI', 'Mangal', serif;
	font-weight: 400; letter-spacing: 0;
}
.dboard__hi { font-size: clamp(2.3rem, 5.2vw, 3.7rem); line-height: 1.3; }
.dboard .dboard__en {
	margin-top: .2rem;
	font-family: var(--disp); font-size: var(--t-lg); line-height: 1.2;
	color: var(--gold-lt);
	font-variation-settings: 'opsz' 40, 'SOFT' 12;
}
.dboard .dboard__addr {
	margin-top: 1.35rem; padding-top: 1.15rem;
	border-top: 1px solid rgba(217, 164, 65, .3);
	font-size: var(--t-lg); line-height: 1.55;
}
.dboard .dboard__addr-en { margin-top: .3rem; font-size: var(--t-sm); color: #A8B4C6; }
.dboard__foot {
	display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between;
	gap: .6rem 1.5rem; margin-top: 1.5rem;
}
.dboard__tel a {
	display: inline-flex; align-items: center; gap: .45em;
	font: 600 clamp(1.3rem, 2.5vw, 1.7rem)/1 var(--ui);
	font-variant-numeric: tabular-nums;
	color: var(--gold-lt); text-decoration: none; white-space: nowrap;
}
.dboard__tel a:hover { color: var(--sand); }
.dboard__tel svg { width: .82em; height: .82em; fill: currentColor; flex: none; }
.dboard__code { font-size: var(--t-sm); color: #A8B4C6; }
.dboard :focus-visible { outline-color: var(--gold-lt); }

.driver__full { margin-top: 1.1rem; }
/* inline-flex on .btn would otherwise beat the hidden attribute. */
.driver__full[hidden] { display: none; }

/* The door itself, in the arch it already has. */
.arch--door { max-width: 22rem; margin-inline: auto; }
.arch--door .arch__frame { aspect-ratio: 3 / 4; --cap: 46px; }

/* ── The card, full screen ────────────────────────────────────────────────── */
.dlg-driver {
	width: 100%; height: 100%; max-width: none; max-height: none;
	margin: 0; padding: 0; border: 0;
	background: var(--ink); color: var(--sand);
}
.dlg-driver[open] { display: flex; }
.dlg-driver::backdrop { background: var(--ink); }
.dlg-driver .dboard {
	flex: 1; margin: 0;
	display: flex; flex-direction: column; justify-content: center;
	padding: 4.8rem 7vw 3rem;
	outline-offset: -14px;
}
.dlg-driver .dboard__hi   { font-size: clamp(2.6rem, 12vmin, 7.5rem); }
.dlg-driver .dboard__en   { font-size: clamp(1.4rem, 4.6vmin, 2.8rem); }
.dlg-driver .dboard__addr { font-size: clamp(1.35rem, 5vmin, 2.6rem); }
.dlg-driver .dboard__addr-en { font-size: clamp(.95rem, 2.6vmin, 1.3rem); }
.dlg-driver .dboard__tel a { font-size: clamp(1.6rem, 6.4vmin, 3.2rem); }
.dlg-driver .dboard__code { font-size: clamp(.95rem, 2.6vmin, 1.3rem); }
.dlg-driver .dboard__foot { margin-top: clamp(1.5rem, 4vmin, 2.6rem); }

/* Labelled, and drawn like the nav sheet's own close. */
.dlg-driver__x {
	/* Inside the gold hairline, not sitting on it. */
	position: absolute; top: 1.55rem; right: 1.6rem; z-index: 1;
	display: flex; flex-direction: column; align-items: center; justify-content: center;
	gap: 3px; width: 46px; height: 44px; padding: 0;
	background: none; border: 0; cursor: pointer;
	color: var(--sand);
}
.dlg-driver__x svg { width: 21px; height: 21px; }
.dlg-driver__x em { font: 600 .625rem/1 var(--ui); letter-spacing: .06em; font-style: normal; }
.dlg-driver__x:hover { color: var(--gold-lt); }
.dlg-driver__x:focus-visible { outline-color: var(--gold-lt); }

/* ── Getting here ─────────────────────────────────────────────────────────── */
.caddr { text-wrap: pretty; }
.caddr span { display: block; margin-top: .35rem; }
.caddr__acts { display: flex; flex-wrap: wrap; gap: .7rem; margin-top: 1.5rem; }

.arrive { margin: 2.2rem 0 0; }
.arrive div { padding: .9rem 0 1rem; border-top: 1px solid var(--line-2); }
.arrive div:last-child { border-bottom: 1px solid var(--line-2); }
.arrive dt { font: 600 var(--t-sm)/1.3 var(--ui); color: var(--ink); margin-bottom: .3rem; }
.arrive dd { margin: 0; font-size: var(--t-sm); line-height: 1.55; color: var(--ink-70); max-width: 48ch; }

/* The map runs the height of the column beside it rather than stopping
   halfway down: more of the lanes, which is the point of it here. */
.cpage .where__in { align-items: stretch; }
.cpage .where__map { aspect-ratio: auto; min-height: 26rem; }

/* ── Narrow screens ───────────────────────────────────────────────────────── */
@media (max-width: 900px) {
	.chero__in { grid-template-columns: 1fr; gap: 2.6rem; }
	.driver__in { grid-template-columns: 1fr; gap: 2.6rem; }
	.arch--door { max-width: 20rem; }
	.cpage .where__map { aspect-ratio: 4 / 3.6; min-height: 0; }
}

@media (max-width: 560px) {
	.chero__acts .btn { flex: 1 1 100%; justify-content: center; }
	/* Four topics as a 2 x 2 rather than three and a stray. */
	.topics__row { display: grid; grid-template-columns: 1fr 1fr; }
	.topics label { text-align: center; }
	.ctimes { grid-template-columns: repeat(3, 1fr); gap: 1rem; }
	.caddr__acts .btn { flex: 1 1 100%; justify-content: center; }
	/* On a phone this is the card's whole purpose, so it gets a full row. */
	.driver__full { width: 100%; justify-content: center; }
	.dboard__foot { flex-direction: column; align-items: flex-start; }
	.dlg-driver .dboard { padding: 4.6rem 1.6rem 2.4rem; }
}

/* Two date fields side by side stop fitting below this. */
@media (max-width: 380px) {
	.compose__set { grid-template-columns: 1fr; }
}
