/* ==========================================================================
   Tennessee Jack's — mobile app (installable web app)
   Matches design/app/app-*.png: black screens, big Anton headlines,
   red brand buttons, cream paper panels, bottom tab bar.
   ========================================================================== */
:root {
  --red: #d71920; --red-dark: #a8121a;
  --black: #0c0a09; --ink: #141110; --card: #171312; --line: rgba(255, 255, 255, 0.16);
  --paper: #efe3cc; --paper-ink: #17120f; --white: #fbf7f1; --text: #e7e0d6; --mute: #b3aaa0;
  --head: "Anton", "Oswald", Impact, sans-serif;
  --label: "Oswald", "Arial Narrow", sans-serif;
  --body: "Barlow", "Helvetica Neue", Arial, sans-serif;
  --tabs-h: 64px;
  --safe-b: env(safe-area-inset-bottom, 0px);
  --safe-t: env(safe-area-inset-top, 0px);
  color-scheme: dark;
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; background: var(--black); color: var(--text); font-family: var(--body); font-size: 16px; line-height: 1.45; -webkit-font-smoothing: antialiased; }
body { min-height: 100vh; min-height: 100dvh; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
img { display: block; max-width: 100%; }
h1, h2, h3, p { margin: 0; }
[hidden] { display: none !important; }
:focus-visible { outline: 2px solid var(--red); outline-offset: 2px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.device-status { display: none; }
.ambient { display: none; }
@keyframes room-drift {
  0%   { transform: scale(1.00) translate(0, 0); }
  50%  { transform: scale(1.06) translate(-1.5%, 1%); }
  100% { transform: scale(1.10) translate(1.5%, -1%); }
}
@media (prefers-reduced-motion: reduce) { .ambient .room { animation: none; } .ambient canvas { display: none; } }


.shell { position: relative; max-width: 480px; margin: 0 auto; min-height: 100vh; min-height: 100dvh; background: var(--black); padding-bottom: calc(var(--tabs-h) + var(--safe-b)); overflow-x: clip; }

/* ---------- top: hamburger, big logo, bell ---------- */
.top { position: relative; z-index: 5; display: grid; grid-template-columns: 56px 1fr 56px; align-items: start; padding: calc(4px + var(--safe-t)) 10px 0;
  background: linear-gradient(180deg, rgba(12, 10, 9, 0.2), var(--black) 96%), url("../assets/img/backdrop.jpg") center 30% / cover; }
.icon-btn { width: 48px; height: 48px; display: grid; place-items: center; background: none; border: 0; color: var(--white); cursor: pointer; position: relative; margin-top: 18px; }
.icon-btn svg { width: 30px; height: 30px; }
.bell .dot { position: absolute; top: 9px; right: 10px; width: 11px; height: 11px; border-radius: 50%; background: var(--red); box-shadow: 0 0 0 2px var(--black); }
.brand { justify-self: center; width: min(52vw, 230px); margin-bottom: -4px; filter: drop-shadow(0 6px 14px rgba(0, 0, 0, 0.6)); }
.brand img { width: 100%; height: auto; }
.page-more .top { display: none; }

/* ---------- baked hero images (mockup art with its headline) ---------- */
.hero-art { position: relative; }
.hero-art img { width: 100%; height: auto; }
.hero-art::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 18%; background: linear-gradient(transparent, var(--black)); pointer-events: none; }
.hero-art.no-fade::after { display: none; }

/* ---------- buttons ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 52px; padding: 0 12px; white-space: nowrap; border: 2px solid var(--white); border-radius: 4px;
  font-family: var(--label); font-weight: 600; font-size: clamp(1rem, 4.9vw, 1.3rem); letter-spacing: 0.02em; text-transform: uppercase; background: transparent; color: var(--white); cursor: pointer; }
.btn svg { width: 22px; height: 22px; }
.btn-red { background: var(--red); border-color: var(--red); box-shadow: 0 8px 20px rgba(215, 25, 32, 0.35); }
.btn-red:active { background: var(--red-dark); }
.btn-dark { background: var(--black); }
.btn-block { width: 100%; }
.btn-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; padding: 6px 16px 0; }

/* ---------- home ---------- */
.features { display: grid; grid-template-columns: repeat(4, 1fr); padding: 18px 6px 14px; }
.features a { display: grid; justify-items: center; gap: 8px; padding: 6px 2px; text-align: center; font-family: var(--label); font-weight: 600; font-size: 0.95rem; text-transform: uppercase; color: var(--white); line-height: 1.1; }
.features a + a { border-left: 1px solid var(--line); }
.features svg { width: 40px; height: 40px; }

.paper-panel { position: relative; background: var(--paper) url("../assets/img/paper.jpg") center / cover; color: var(--paper-ink); padding: 22px 16px 18px; margin-top: 6px; }
.paper-panel::before { content: ""; position: absolute; left: 0; right: 0; top: -7px; height: 8px; background: linear-gradient(-45deg, var(--paper) 4px, transparent 0) 0 0 / 10px 8px repeat-x, linear-gradient(45deg, var(--paper) 4px, transparent 0) 0 0 / 10px 8px repeat-x; }
.panel-head { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; margin-bottom: 12px; }
.panel-head h2 { font-family: var(--head); font-weight: 400; font-size: 2.1rem; line-height: 1; text-transform: uppercase; letter-spacing: 0.01em; }
.panel-head h2 .red, .red { color: var(--red); }
.panel-head a { font-family: var(--label); font-weight: 600; color: var(--red); text-transform: uppercase; white-space: nowrap; }

/* event card (home + events) */
.ev-card { position: relative; display: grid; grid-template-columns: 1fr auto; align-items: end; min-height: 150px; border-radius: 8px; overflow: hidden; color: var(--white); border: 1px solid rgba(255, 255, 255, 0.18); background: #111; box-shadow: 0 10px 24px rgba(0, 0, 0, 0.45); text-align: left; width: 100%; padding: 0; cursor: pointer; }
.ev-card img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.ev-card::before { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(0, 0, 0, 0.94) 0%, rgba(0, 0, 0, 0.82) 42%, rgba(0, 0, 0, 0.2) 80%), linear-gradient(0deg, rgba(0, 0, 0, 0.65), transparent 60%); }
.ev-card h3, .ev-card .meta, .ev-card .day { text-shadow: 0 2px 6px rgba(0, 0, 0, 0.8); }
.ev-card .txt { position: relative; padding: 12px 14px 12px; display: grid; gap: 0; }
.ev-card .mon { font-family: var(--head); color: var(--red); font-size: 1.7rem; line-height: 1; }
.ev-card .day { font-family: var(--head); font-size: 2.9rem; line-height: 0.95; margin-bottom: 10px; }
.ev-card .type { font-family: var(--label); font-weight: 600; color: var(--red); text-transform: uppercase; font-size: 1.15rem; line-height: 1.1; }
.ev-card h3 { font-family: var(--label); font-weight: 700; font-size: 1.45rem; line-height: 1.1; text-transform: uppercase; }
.ev-card h3.red { color: var(--red); }
.ev-card .meta { font-size: 1.02rem; color: #eee; }
.ev-card .chev { position: relative; padding: 0 14px 18px; }
.ev-card .chev svg, .item-card .chev svg, .more-list .chev svg { width: 14px; height: 24px; }

.specials { display: grid; gap: 10px; margin-top: 14px; }
.special { display: grid; grid-template-columns: 64px 1fr; gap: 12px; align-items: center; background: rgba(23, 18, 15, 0.06); border: 1px solid rgba(23, 18, 15, 0.18); border-radius: 6px; padding: 8px; }
.special img { width: 64px; height: 52px; object-fit: cover; border-radius: 4px; }
.special b { display: block; font-family: var(--label); font-weight: 700; text-transform: uppercase; font-size: 1.05rem; line-height: 1.1; }
.special span { font-size: 0.95rem; }

/* ---------- chips (menu categories, event filters) ---------- */
.chips { display: flex; gap: 8px; overflow-x: auto; padding: 14px 16px 6px; scrollbar-width: none; scroll-snap-type: x proximity; }
.chips::-webkit-scrollbar { display: none; }
.chips button { flex: none; scroll-snap-align: start; padding: 9px 15px; border-radius: 10px; border: 1px solid rgba(255, 255, 255, 0.35); background: #1b1715; color: var(--white); font-family: var(--label); font-size: 1.05rem; cursor: pointer; }
.chips button[aria-pressed="true"] { background: var(--red); border-color: var(--red); }

/* ---------- menu ---------- */
.list { display: grid; gap: 12px; padding: 10px 16px 18px; }
.cat-title { font-family: var(--head); font-weight: 400; font-size: 1.6rem; text-transform: uppercase; color: var(--white); margin: 10px 0 -2px; letter-spacing: 0.01em; }
.cat-title span { color: var(--red); }
.item-card { display: grid; grid-template-columns: 44% 1fr auto; align-items: center; min-height: 128px; background: var(--card); border: 1px solid rgba(255, 255, 255, 0.2); border-radius: 8px; overflow: hidden; text-align: left; width: 100%; padding: 0; color: var(--white); cursor: pointer; box-shadow: 0 8px 18px rgba(0, 0, 0, 0.35); }
.item-card .ph { align-self: stretch; position: relative; background: #0f0c0b; }
.item-card .ph img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.item-card .ph.empty { display: grid; place-items: center; background: radial-gradient(circle at 50% 40%, #2a1c19, #0f0c0b 70%); }
.item-card .ph.empty img { position: static; width: 70%; height: auto; opacity: 0.85; }
.item-card .txt { padding: 12px 6px 12px 16px; display: grid; gap: 4px; min-width: 0; }
.item-card h3 { font-family: var(--head); font-weight: 400; font-size: 1.45rem; line-height: 1.05; text-transform: uppercase; letter-spacing: 0.01em; }
.item-card p { font-size: 0.98rem; color: #e9e3da; line-height: 1.3; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.item-card .price { font-family: var(--label); font-weight: 700; font-size: 1.3rem; margin-top: 2px; }
.item-card .chev { padding: 0 14px 0 4px; }
.empty-note { padding: 30px 20px; text-align: center; color: var(--mute); }

/* ---------- private parties ---------- */
.parties-panel { margin-top: -10px; padding-top: 24px; }
.parties-panel h2 { font-family: var(--head); font-weight: 400; font-size: 2.6rem; line-height: 1; text-transform: uppercase; }
.parties-panel > p { font-size: 1.1rem; margin: 10px 0 14px; }
.checks { display: grid; grid-template-columns: 1fr 1fr; gap: 10px 14px; margin: 0 0 18px; padding: 0; list-style: none; }
.checks li { display: flex; gap: 10px; align-items: center; font-size: 1.02rem; line-height: 1.2; }
.checks li::before { content: ""; flex: none; width: 24px; height: 24px; border-radius: 50%; background: var(--red) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M6 12.5l4 4 8-9' fill='none' stroke='white' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 16px no-repeat; }

/* ---------- more ---------- */
.more-head { position: relative; padding-top: var(--safe-t); background: var(--black); }
.more-head img { width: 100%; }
.more-list { list-style: none; margin: 0; padding: 0 16px 20px; }
.more-list a, .more-list button { display: grid; grid-template-columns: 52px 1fr auto; align-items: center; gap: 4px; width: 100%; min-height: 62px; padding: 6px 4px; border: 0; border-bottom: 1px solid var(--line); background: none; color: var(--white); font-size: 1.3rem; text-align: left; cursor: pointer; }
.more-list svg.ic { width: 30px; height: 30px; }

/* ---------- inner pages (story, gallery, visit, social, careers, settings, order) ---------- */
.page-head { padding: 8px 16px 6px; }
.page-head h1 { font-family: var(--head); font-weight: 400; font-size: 2.7rem; line-height: 1; text-transform: uppercase; color: var(--white); }
.page-head h1 .red { color: var(--red); }
.page-head p { margin-top: 6px; color: var(--mute); font-family: var(--label); text-transform: uppercase; letter-spacing: 0.03em; }
.block { padding: 12px 16px; display: grid; gap: 12px; }
.block p { font-size: 1.05rem; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: 8px; padding: 16px; display: grid; gap: 10px; }
.card h2 { font-family: var(--label); font-weight: 600; font-size: 1.3rem; text-transform: uppercase; color: var(--white); }
.rows { display: grid; gap: 2px; }
.rows div { display: flex; justify-content: space-between; gap: 12px; padding: 6px 0; border-bottom: 1px solid rgba(255, 255, 255, 0.08); }
.rows div:last-child { border: 0; }
.why { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.why div { background: var(--card); border: 1px solid var(--line); border-radius: 8px; padding: 14px; }
.why b { display: block; font-family: var(--label); font-weight: 700; text-transform: uppercase; color: var(--white); }
.why span { font-size: 0.95rem; color: var(--mute); }
.gallery { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; padding: 6px 16px 18px; }
.gallery figure { margin: 0; aspect-ratio: 1; border-radius: 6px; overflow: hidden; background: #111; position: relative; }
.gallery img { width: 100%; height: 100%; object-fit: cover; }
.gallery figcaption { position: absolute; left: 0; right: 0; bottom: 0; padding: 14px 8px 6px; font-size: 0.85rem; background: linear-gradient(transparent, rgba(0, 0, 0, 0.8)); }

/* forms */
.form { display: grid; gap: 10px; }
.form label { display: grid; gap: 4px; font-family: var(--label); font-size: 0.95rem; text-transform: uppercase; letter-spacing: 0.03em; color: var(--mute); }
.form input, .form select, .form textarea { width: 100%; padding: 12px 12px; border-radius: 6px; border: 1px solid rgba(255, 255, 255, 0.28); background: #0f0c0b; color: var(--white); font-family: var(--body); font-size: 1.05rem; text-transform: none; letter-spacing: 0; }
.form textarea { min-height: 96px; resize: vertical; }
.form .two { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.form .status { min-height: 1.3em; color: var(--white); font-weight: 600; }
.form .hp { position: absolute; left: -9999px; }

/* ---------- bottom tab bar ---------- */
.tabs { position: fixed; z-index: 20; left: 50%; bottom: 0; transform: translateX(-50%); width: 100%; max-width: 480px; display: grid; grid-template-columns: repeat(5, 1fr);
  height: calc(var(--tabs-h) + var(--safe-b)); padding-bottom: var(--safe-b); background: rgba(10, 8, 7, 0.96); border-top: 1px solid rgba(255, 255, 255, 0.12); backdrop-filter: blur(10px); }
.tabs a { position: relative; display: grid; justify-items: center; align-content: center; gap: 3px; color: var(--white); font-size: 0.9rem; }
.tabs svg { width: 28px; height: 28px; }
.tabs a.on { color: var(--red); }
.tabs a.on::after { content: ""; position: absolute; bottom: 4px; width: 46px; height: 3px; border-radius: 2px; background: var(--red); }

/* ---------- bottom sheet (dish, event, forms, what's new) ---------- */
.sheet { position: fixed; inset: 0; z-index: 50; background: rgba(0, 0, 0, 0.6); display: flex; align-items: flex-end; justify-content: center; }
.sheet-panel { position: relative; width: 100%; max-width: 480px; max-height: 92vh; max-height: 92dvh; overflow-y: auto; background: var(--ink); border-radius: 16px 16px 0 0; border-top: 1px solid var(--line); padding: 10px 16px calc(20px + var(--safe-b)); animation: up .22s ease; }
@keyframes up { from { transform: translateY(40px); opacity: 0.5; } }
@media (prefers-reduced-motion: reduce) { .sheet-panel { animation: none; } }
.sheet-grab { width: 44px; height: 5px; border-radius: 3px; background: rgba(255, 255, 255, 0.3); margin: 0 auto 10px; }
.sheet-close { position: absolute; top: 8px; right: 10px; width: 40px; height: 40px; border: 0; border-radius: 50%; background: rgba(255, 255, 255, 0.1); color: #fff; font-size: 1.6rem; line-height: 1; cursor: pointer; }
.sheet-body { display: grid; gap: 12px; }
.sheet-body > img { width: calc(100% + 32px); margin: 0 -16px; max-height: 260px; object-fit: cover; }
.sheet-body h2 { font-family: var(--head); font-weight: 400; font-size: 2rem; line-height: 1.05; text-transform: uppercase; color: var(--white); padding-right: 40px; }
.sheet-body .price { font-family: var(--label); font-weight: 700; font-size: 1.6rem; color: var(--white); }
.sheet-body .when { font-family: var(--label); font-size: 1.15rem; color: var(--red); text-transform: uppercase; }
.tags { display: flex; flex-wrap: wrap; gap: 6px; }
.tags span { padding: 4px 10px; border-radius: 99px; background: rgba(255, 255, 255, 0.1); font-size: 0.9rem; }
.news { display: grid; gap: 8px; }
.news a { display: grid; grid-template-columns: 56px 1fr; gap: 12px; align-items: center; padding: 8px; border-radius: 8px; background: var(--card); border: 1px solid var(--line); }
.news img { width: 56px; height: 56px; object-fit: cover; border-radius: 6px; }
.news b { display: block; color: var(--white); font-family: var(--label); text-transform: uppercase; }
.news .new { display: inline-block; margin-left: 6px; padding: 1px 6px; border-radius: 4px; background: var(--red); color: #fff; font-size: 0.75rem; vertical-align: 2px; }

.toast { position: fixed; z-index: 60; left: 50%; bottom: calc(var(--tabs-h) + var(--safe-b) + 14px); transform: translate(-50%, 20px); opacity: 0; pointer-events: none; background: #fff; color: #111; padding: 10px 16px; border-radius: 8px; font-weight: 600; transition: opacity .2s, transform .2s; max-width: 90vw; }
.toast.show { opacity: 1; transform: translate(-50%, 0); }
/* two buttons side by side always fit, even on small phones */
.btn-row .btn { min-width: 0; padding: 0 8px; font-size: clamp(0.95rem, 4.4vw, 1.3rem); }
.btn-row .btn svg { width: 18px; height: 18px; flex: none; }

/* Kept last so it overrides the base .shell / .tabs / .sheet rules above. */
/* On tablets / desktop the app shows inside a phone (like design/app/*), on the website's
   plain page background (#050404). The screen is its own scroll area; the transform makes the
   fixed tab bar, sheet and toast stay inside the phone. On a real phone none of this applies. */
@media (min-width: 560px) and (min-height: 640px) {
  /* same moving backdrop as the website: the blurred bar slowly drifting, warm lights floating up */
  html, body { background: #0b0908; }
  .ambient { display: block; position: fixed; inset: 0; z-index: 0; overflow: hidden; pointer-events: none; }
  .ambient .room { position: absolute; inset: -6%; background: url("../assets/img/backdrop.jpg") center / cover no-repeat; animation: room-drift 48s ease-in-out infinite alternate; }
  .ambient canvas { position: absolute; inset: 0; width: 100%; height: 100%; mix-blend-mode: screen; }
  .ambient::after { content: ""; position: absolute; inset: 0; background: radial-gradient(ellipse at center, rgba(0, 0, 0, 0.05) 45%, rgba(0, 0, 0, 0.5) 100%); }
  .device { z-index: 1; }
  body { display: grid; place-items: center; min-height: 100vh; min-height: 100dvh; padding: 24px; }
  .device { position: relative; width: 414px; height: min(868px, calc(100dvh - 48px)); padding: 12px; border-radius: 62px;
    background: linear-gradient(145deg, #2b2b2e, #0d0d0f 40%, #1c1c1f); box-shadow: inset 0 0 0 2px #3a3a3e, inset 0 0 0 5px #08080a, 0 30px 70px rgba(0, 0, 0, 0.75); }
  /* side buttons */
  .device::before { content: ""; position: absolute; left: -3px; top: 150px; width: 4px; height: 96px; border-radius: 2px 0 0 2px; background: #2a2a2d;
    box-shadow: 0 -52px 0 -10px #2a2a2d; }
  .device::after { content: ""; position: absolute; right: -3px; top: 190px; width: 4px; height: 92px; border-radius: 0 2px 2px 0; background: #2a2a2d; }
  .device-screen { --safe-t: 44px; --safe-b: 16px; position: relative; height: 100%; border-radius: 50px; overflow: hidden; background: var(--black); transform: translateZ(0); }
  /* dynamic island + status bar */
  .device-screen::before { content: ""; position: absolute; z-index: 40; top: 11px; left: 50%; width: 118px; height: 34px; margin-left: -59px; border-radius: 20px; background: #000; }
  .device-status { position: absolute; z-index: 39; inset: 0 0 auto; height: 50px; background: linear-gradient(180deg, var(--black) 70%, rgba(12, 10, 9, 0)); display: flex; align-items: center; justify-content: space-between; padding: 6px 30px 0 40px; pointer-events: none;
    font-family: -apple-system, "SF Pro Text", var(--body); font-weight: 600; font-size: 16px; color: #fff; }
  .device-icons { display: flex; gap: 6px; align-items: center; }
  .device-icons svg { height: 12px; width: auto; }
  /* home indicator */
  .device-screen::after { content: ""; position: absolute; z-index: 41; bottom: 7px; left: 50%; width: 134px; height: 5px; margin-left: -67px; border-radius: 3px; background: rgba(255, 255, 255, 0.85); pointer-events: none; }
  .shell { height: 100%; min-height: 0; max-width: none; overflow-y: auto; overscroll-behavior: contain; scrollbar-width: none; }
  .shell::-webkit-scrollbar { display: none; }
  .tabs { max-width: none; }
  .sheet-panel { max-width: none; max-height: 88%; }
  .toast { max-width: 86%; }
}
