/* Dark Essex – marsh-and-mist pages (based on Dark Kent), in the app's own style. Fonts are served from this folder (no third-party requests). */
@font-face { font-family: 'Fell SC'; src: url(../darkkent/fonts/IMFellEnglishSC_400Regular.ttf); font-display: swap; }
@font-face { font-family: 'Fell'; font-style: italic; src: url(../darkkent/fonts/IMFellEnglish_400Regular_Italic.ttf); font-display: swap; }
@font-face { font-family: 'Spectral'; font-weight: 400; src: url(../darkkent/fonts/Spectral_400Regular.ttf); font-display: swap; }
@font-face { font-family: 'Spectral'; font-weight: 600; src: url(../darkkent/fonts/Spectral_600SemiBold.ttf); font-display: swap; }

:root {
  --night: #0a0e0d; --panel: #121a18; --line: #24332f; --bronze: #4a5e57;
  --candle: #e3c77a; --flame: #f3e3b0; --bone: #e4e8e2; --parchment: #dfe6dc; --muted: #a3b3ab; --wax: #3d5a50; --spectral: #7fd6c8;
}
* { box-sizing: border-box; }
html { background: var(--night); }
body { margin: 0; color: var(--bone); font: 17px/1.65 Spectral, Georgia, serif; background: var(--night); }
a { color: var(--candle); }
a:hover { color: var(--flame); }
h1, h2, h3 { font-family: 'Fell SC', Georgia, serif; font-weight: 400; color: var(--parchment); line-height: 1.1; margin: 0; text-wrap: balance; }
h2 { font-size: clamp(28px, 5vw, 40px); }
h3 { font-size: 22px; }
p { margin: 0 0 1em; text-wrap: pretty; }
.wrap { max-width: 1060px; margin: 0 auto; padding: 0 22px; }
.italic { font-family: Fell, Georgia, serif; font-style: italic; }
.muted { color: var(--muted); }
.skip { position: absolute; left: -999px; }
.skip:focus { left: 12px; top: 12px; background: var(--candle); color: #0a0e0d; padding: 8px 12px; z-index: 9; }

/* Top bar */
.top { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 18px 22px; max-width: 1060px; margin: 0 auto; }
.brand { display: flex; align-items: center; gap: 12px; font-family: 'Fell SC', serif; font-size: 22px; color: var(--parchment); text-decoration: none; letter-spacing: 1px; }
.brand img { width: 38px; height: 38px; border-radius: 9px; }
.nav { display: flex; gap: 20px; flex-wrap: wrap; font-size: 15px; }
.nav a { text-decoration: none; color: var(--muted); }
.nav a:hover, .nav a[aria-current] { color: var(--candle); }

/* The old map, dark and flickering */
.hero { position: relative; overflow: hidden; min-height: 78vh; display: flex; align-items: center; border-bottom: 1px solid var(--line); }
.hero .map { position: absolute; inset: -4%; background: none; filter: sepia(.4) brightness(.38) contrast(1.1); transform: scale(1.04); animation: drift 40s ease-in-out infinite alternate; }
.hero::after { content: ''; position: absolute; inset: 0; background: radial-gradient(ellipse at 50% 45%, rgba(227,199,122,.18), rgba(10,14,13,0) 45%), radial-gradient(ellipse at 50% 50%, rgba(10,14,13,0) 40%, rgba(10,14,13,.92) 100%); animation: flicker 5s infinite; pointer-events: none; }
.hero .inner { position: relative; z-index: 1; text-align: center; padding: 70px 22px; max-width: 760px; margin: 0 auto; }
.hero h1 { font-size: clamp(52px, 11vw, 104px); letter-spacing: 3px; text-shadow: 0 0 30px rgba(227,199,122,.55); }
.hero .tag { font-family: Fell, serif; font-style: italic; font-size: clamp(19px, 3vw, 24px); color: var(--muted); margin-top: 6px; }
.hero .lead { margin: 22px auto 28px; font-size: 19px; max-width: 600px; }
@keyframes drift { from { transform: scale(1.04) translate(0, 0); } to { transform: scale(1.1) translate(-1.5%, 1%); } }
@keyframes flicker { 0%, 100% { opacity: 1; } 42% { opacity: .86; } 50% { opacity: .97; } 63% { opacity: .82; } 80% { opacity: .95; } }
@media (prefers-reduced-motion: reduce) { .hero .map, .hero::after { animation: none; } }

/* Buttons */
.stores { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 52px; padding: 0 24px; border-radius: 26px; background: var(--candle); color: #0a0e0d; font-family: 'Fell SC', serif; font-size: 19px; text-decoration: none; box-shadow: 0 0 24px rgba(227,199,122,.35); border: 0; cursor: pointer; }
.btn:hover { background: var(--flame); color: #0a0e0d; }
.btn.dim { background: transparent; color: var(--bone); border: 1px solid var(--bronze); box-shadow: none; }
.btn.dim:hover { border-color: var(--candle); color: var(--candle); }
.btn[aria-disabled="true"] { opacity: .55; pointer-events: none; }
.small { font-size: 14px; color: var(--muted); }

/* Sections */
section { padding: 70px 0; border-bottom: 1px solid var(--line); }
.parch { background: linear-gradient(180deg, #0d1412, #111b18); }
.grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 18px; margin-top: 28px; }
.card { background: rgba(18,26,24,.9); border: 1px solid var(--line); border-radius: 16px; padding: 20px; }
.card h3 { margin-bottom: 6px; }
.card p { margin: 0; color: var(--muted); font-size: 15.5px; }
.seal { width: 46px; height: 46px; margin-bottom: 12px; }

/* Tales strip */
.tales { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 14px; margin-top: 28px; }
.tale { margin: 0; border-radius: 12px; overflow: hidden; border: 1px solid var(--line); background: var(--panel); }
.tale img { display: block; width: 100%; aspect-ratio: 4 / 3; object-fit: cover; filter: sepia(.25); }
.tale figcaption { padding: 10px 12px 12px; font-size: 14px; color: var(--muted); }
.tale figcaption b { display: block; font-family: 'Fell SC', serif; font-weight: 400; font-size: 17px; color: var(--parchment); }

.split { display: flex; flex-wrap: wrap; gap: 30px; align-items: center; }
.split > * { flex: 1 1 320px; min-width: 0; }
.quote { border-left: 0; padding: 22px; border-radius: 16px; background: rgba(18,26,24,.92); border: 1px solid var(--bronze); }

/* Pubs */
.plans { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 18px; margin-top: 26px; }
.plan { border-radius: 16px; padding: 24px; border: 1px solid var(--bronze); background: rgba(18,26,24,.9); }
.plan.featured { border: 2px solid var(--spectral); background: rgba(17,24,22,.92); }
.plan .price { font-family: 'Fell SC', serif; font-size: 44px; color: var(--parchment); line-height: 1; margin: 10px 0 4px; }
.plan ul { margin: 14px 0 0; padding-left: 20px; }
.plan li { margin: 6px 0; }
.spectral { color: var(--spectral); }

/* Long text pages */
.page { max-width: 760px; margin: 0 auto; padding: 40px 22px 70px; }
.page h1 { font-size: clamp(38px, 7vw, 56px); margin-bottom: 8px; }
.page h2 { font-size: 26px; margin: 34px 0 10px; }
.page li { margin: 6px 0; }

footer { padding: 40px 22px 60px; text-align: center; color: var(--muted); font-size: 14px; }
footer nav { display: flex; gap: 18px; justify-content: center; flex-wrap: wrap; margin-bottom: 12px; }
footer a { color: var(--muted); }
:focus-visible { outline: 2px solid var(--candle); outline-offset: 3px; }

@media (max-width: 520px) {
  .top { flex-wrap: wrap; padding: 14px 18px; gap: 8px 16px; }
  .brand { white-space: nowrap; font-size: 20px; }
  .nav { gap: 14px; font-size: 14px; }
  .hero { min-height: 0; }
}

/* Mist drifting across the map, at two speeds */
.mist { position: absolute; left: 0; right: 0; pointer-events: none; background-repeat: repeat-x; background-size: 1800px 100%; }
.mist.m1 { bottom: -4%; height: 62%; background-image: url(../darkkent/img/mist-1.png); opacity: .26; animation: mist 95s linear infinite; }
.mist.m2 { top: 18%; height: 48%; background-image: url(../darkkent/img/mist-2.png); background-size: 1800px 100%; opacity: .14; animation: mist 160s linear infinite reverse; }
.mist.low { top: auto; bottom: -10%; height: 90%; opacity: .2; }
@keyframes mist { from { background-position: 0 0; } to { background-position: -1800px 0; } }

/* Embers rising from the candle glow */
.embers { position: absolute; inset: 0; pointer-events: none; overflow: hidden; }
.embers span { position: absolute; bottom: -10px; width: 3px; height: 3px; border-radius: 50%; background: #e9dba4; box-shadow: 0 0 6px 2px rgba(227,199,122,.55); opacity: 0; animation: ember 11s linear infinite; }
@keyframes ember {
  0% { transform: translate(0, 0); opacity: 0; }
  10% { opacity: .9; }
  60% { opacity: .5; }
  100% { transform: translate(var(--dx, 20px), -85vh); opacity: 0; }
}

/* Sections rise out of the dark as you scroll (only when scripts run) */
.js .reveal { opacity: 0; transform: translateY(18px); transition: opacity 1.1s ease, transform 1.1s ease; }
.js .reveal.in { opacity: 1; transform: none; }

/* The title breathes like a candle flame */
.hero h1 { animation: glow 4.5s ease-in-out infinite; }
@keyframes glow { 0%, 100% { text-shadow: 0 0 30px rgba(227,199,122,.55); } 45% { text-shadow: 0 0 44px rgba(227,199,122,.75), 0 0 4px rgba(243,227,176,.4); } 70% { text-shadow: 0 0 24px rgba(227,199,122,.45); } }

@media (prefers-reduced-motion: reduce) {
  .mist, .hero h1 { animation: none; }
  .embers { display: none; }
  .js .reveal { opacity: 1; transform: none; transition: none; }
}

/* Sign-up form for pubs */
.signup { max-width: 720px; margin-top: 22px; display: grid; gap: 16px; }
.signup fieldset { border: 1px solid var(--line); border-radius: 14px; padding: 12px 16px 14px; margin: 0; display: grid; gap: 8px; }
.signup legend { padding: 0 6px; color: var(--parchment); font-family: 'Fell SC', Georgia, serif; font-size: 18px; }
.signup label { display: grid; gap: 6px; color: var(--parchment); font-size: 16px; }
.signup .row { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; }
.signup input:not([type=radio]):not([type=checkbox]), .signup select, .signup textarea {
  font: 16px/1.5 Spectral, Georgia, serif; color: var(--bone); background: rgba(18,26,24,.9); border: 1px solid var(--bronze);
  border-radius: 10px; padding: 10px 12px; min-height: 46px; box-sizing: border-box; width: 100%; }
.signup textarea { resize: vertical; }
.signup input:focus, .signup select:focus, .signup textarea:focus { outline: 2px solid var(--candle); outline-offset: 1px; border-color: var(--candle); }
.signup .choice, .signup .agree { display: flex; align-items: flex-start; gap: 10px; color: var(--bone); cursor: pointer; }
.signup .choice input, .signup .agree input { width: 20px; height: 20px; margin-top: 4px; accent-color: var(--candle); flex: none; }
.signup .agree { font-size: 15px; color: var(--muted); }
.signup .hint { font-size: 14px; color: var(--muted); font-style: italic; }
.signup .req { color: var(--candle); }
.signup .hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.signup button[disabled] { opacity: .6; }
[hidden] { display: none !important; }
.formmsg { max-width: 720px; margin-top: 18px; padding: 16px 18px; border-radius: 14px; border: 1px solid var(--candle); background: rgba(227,199,122,.08); }
.formmsg.err { border-color: #c0573f; background: rgba(192,87,63,.12); }

/* Waystation Apps – a small note and a menu of our other apps that opens upwards (as on the other app sites) */
.ws { display: flex; align-items: center; justify-content: center; gap: 10px; flex-wrap: wrap; margin-top: 10px; }
.ws details { position: relative; }
.ws summary { list-style: none; display: inline-flex; align-items: center; gap: 6px; cursor: pointer; border: 1px solid var(--bronze); background: var(--panel); color: var(--candle); border-radius: 999px; padding: 5px 10px 5px 13px; font-size: 13px; font-weight: 600; }
.ws summary::-webkit-details-marker { display: none; }
.ws summary svg { width: 16px; height: 16px; transition: transform .15s; }
.ws details[open] summary svg { transform: rotate(180deg); }
.ws summary:hover { color: var(--flame); border-color: var(--candle); }
.ws summary:focus-visible { outline: 2px solid var(--candle); outline-offset: 2px; }
.ws-menu { position: absolute; bottom: calc(100% + 8px); left: 50%; transform: translateX(-50%); width: 300px; max-width: calc(100vw - 32px); background: var(--panel); border: 1px solid var(--bronze); border-radius: 14px; box-shadow: 0 14px 40px rgba(0,0,0,.6); padding: 8px; text-align: left; z-index: 10; }
.ws-head { font-size: 12px; color: var(--muted); padding: 6px 8px 8px; line-height: 1.4; }
.ws-head b { display: block; color: var(--parchment); font-size: 13.5px; }
.ws-item { display: flex; align-items: center; gap: 12px; padding: 9px 8px; border-radius: 10px; text-decoration: none; color: var(--bone); }
.ws-item:hover, .ws-item:focus-visible { background: #1a2522; outline: none; color: var(--bone); }
.ws-item svg, .ws-item img { width: 38px; height: 38px; border-radius: 10px; flex: none; display: block; }
.ws-item span { flex: 1; min-width: 0; font-size: 12.5px; color: var(--muted); line-height: 1.35; }
.ws-item b { display: block; font-size: 14.5px; color: var(--parchment); font-weight: 600; }
.ws-item i { font-style: normal; color: var(--muted); font-size: 18px; }
.ws-all { display: flex; justify-content: space-between; margin-top: 4px; padding: 11px 8px 7px; border-top: 1px solid var(--line); font-size: 13.5px; font-weight: 600; color: var(--candle); text-decoration: none; }
.ws-all:hover, .ws-all:focus-visible { text-decoration: underline; }

/* Waystation Apps in the top bar: a small pill beside Privacy */
.nav a.nav-ws { border: 1px solid var(--bronze); border-radius: 999px; padding: 1px 11px; color: var(--candle); }
.nav a.nav-ws:hover { border-color: var(--candle); color: var(--flame); }
@media (max-width: 420px) { .nav { gap: 11px; font-size: 13px; } .nav a.nav-ws { padding: 1px 9px; } }

/* Waystation Apps page */
.wsa .kicker { font-family: 'Fell SC', Georgia, serif; letter-spacing: 2px; color: var(--candle); margin: 0 0 6px; }
.wsa .lead { color: var(--muted); font-size: 18px; max-width: 680px; margin-top: 12px; }
.wsa-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 16px; margin: 28px 0 26px; }
.wsa .card { position: relative; display: flex; flex-direction: column; gap: 12px; padding: 18px; border: 1px solid var(--line); border-radius: 14px; background: var(--panel); }
.wsa .card.here { border-color: var(--candle); box-shadow: 0 0 28px rgba(227,199,122,.18); }
.wsa .card .wsa-top { display: flex; gap: 14px; align-items: center; }
.wsa .card .wsa-top img, .wsa .card .wsa-top svg { width: 56px; height: 56px; border-radius: 14px; flex: none; display: block; }
.wsa .card h2 { font-size: 24px; }
.wsa .card .tag { margin: 4px 0 0; color: var(--muted); font-size: 14.5px; line-height: 1.35; }
.wsa .card .about { margin: 0; font-size: 15.5px; line-height: 1.55; color: var(--bone); flex: 1; }
.wsa .badge { position: absolute; top: 14px; right: 14px; font-size: 12px; padding: 2px 10px; border-radius: 999px; background: var(--candle); color: var(--night); font-weight: 600; }
.wsa .wsa-btn { display: flex; justify-content: space-between; align-items: center; padding: 10px 14px; border-radius: 10px; border: 1px solid var(--bronze); color: var(--candle); text-decoration: none; font-weight: 600; font-size: 15px; }
.wsa .wsa-btn:hover { border-color: var(--candle); color: var(--flame); }
.wsa .small { color: var(--muted); font-size: 13.5px; }
.page.wsa { max-width: 1060px; } .wsa .card.here .wsa-top { padding-right: 86px; }

/* Dark Essex extras: the marsh line along the foot of the hero, the lantern and the tale dates */
.hero { background: radial-gradient(ellipse at 50% 38%, rgba(227,199,122,.12), transparent 42%), linear-gradient(180deg, #0a0e0d 0%, #101917 55%, #17231f 100%); }
.hero::after { background: radial-gradient(ellipse at 50% 50%, rgba(10,14,13,0) 45%, rgba(10,14,13,.85) 100%); }
.hero h1 { text-shadow: 0 0 28px rgba(143,163,154,.45); animation: none; }
.marsh { position: absolute; left: 0; right: 0; bottom: 0; height: 90px; pointer-events: none; z-index: 1; }
.lantern { width: 74px; height: 74px; margin: 0 auto 18px; display: block; filter: drop-shadow(0 0 18px rgba(227,199,122,.45)); animation: lamp 5s ease-in-out infinite; }
@keyframes lamp { 0%,100% { opacity: 1; } 47% { opacity: .82; } 52% { opacity: .95; } }
.soon { display: inline-block; padding: 10px 22px; border: 1px solid #8fa39a; border-radius: 24px; font-family: 'Fell SC', serif; font-size: 19px; color: #d8c486; }
.card h3 { color: #d8c486; }
.card .when { font-size: 14px; color: #9d8aa8; margin: 0 0 8px; }
@media (prefers-reduced-motion: reduce) { .lantern { animation: none; } }

/* Sister app band */
.sister { padding: 34px 0; border-top: 1px solid var(--bronze); border-bottom: 1px solid var(--bronze); background: radial-gradient(ellipse at 20% 50%, rgba(232,168,74,.14), transparent 60%), #0b0907; }
.sister .row { display: flex; flex-wrap: wrap; gap: 22px; align-items: center; }
.sister img.icon { width: 96px; height: 96px; border-radius: 22px; box-shadow: 0 0 30px rgba(232,168,74,.35); flex: none; }
.sister .txt { flex: 1 1 300px; min-width: 0; }
.sister .new { display: inline-block; font-family: 'Fell SC', serif; font-size: 15px; letter-spacing: .08em; color: #1a110a; background: var(--candle); padding: 3px 12px; border-radius: 12px; margin-bottom: 8px; }
.sister h2 { margin: 0 0 6px; }
.sister p { margin: 0; }
.sister .stores { justify-content: flex-start; flex: 1 1 260px; }
