/* Cotinerary site styles, from the "Cotinerary Site" Claude Design project.
   Itinerary colors are the app's (theme.colors.custom in apps/cotinerary-app/lib/styles/theme.ts):
   stays blue, activities amber, transportation green. Keep them in sync. */
:root {
    --bg: #f9f9ff;
    --surface: #ffffff;
    --text: #191c20;
    --muted: #44474e;
    --subtle: #74777f;
    --border: #e0e2ec;
    --outline: #c4c6d0;
    --primary: #415f91;
    --primary-hover: #284777;
    --primary-container: #d6e3ff;
    --navy: #1b2a42;
    --inverse-surface: #2e3036;

    --stay: #1746a0;
    --activity: #d6a028;
    --transport: #218c5b;

    --radius: 8px;
    --max: 1120px;
    --prose: 760px;
    --font: Montserrat, -apple-system, Roboto, sans-serif;
    --mono: 'Space Mono', ui-monospace, Menlo, monospace;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

body {
    margin: 0;
    background: var(--bg);
    color: var(--text);
    font-family: var(--font);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

img {
    display: block;
    max-width: 100%;
}

a {
    color: var(--primary);
}

a:hover {
    color: var(--primary-hover);
}

code,
pre {
    font-family: var(--mono);
    font-size: 0.88em;
}

:not(pre) > code {
    background: var(--border);
    padding: 0.1em 0.35em;
    border-radius: 4px;
    word-break: break-word;
}

.container {
    max-width: var(--max);
    margin: 0 auto;
    padding: 0 20px;
}

.skip-link {
    position: absolute;
    left: -999px;
}

.skip-link:focus {
    left: 16px;
    top: 16px;
    z-index: 100;
    background: var(--surface);
    padding: 8px 12px;
}

/* Header */
.site-header {
    position: sticky;
    top: 0;
    z-index: 10;
    background: rgb(249 249 255 / 0.94);
    border-bottom: 1px solid var(--border);
}

.site-header .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding-top: 12px;
    padding-bottom: 12px;
}

.brand {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    color: var(--text);
    font-weight: 700;
    font-size: 17px;
}

.brand:hover {
    color: var(--text);
}

.brand img {
    width: 32px;
    height: 32px;
    border-radius: 8px;
}

.site-nav {
    display: flex;
    align-items: center;
    gap: 24px;
}

.button-pill {
    background: var(--primary);
    color: #fff;
    text-decoration: none;
    font-weight: 600;
    font-size: 13px;
    padding: 10px 16px;
    border-radius: 9999px;
    white-space: nowrap;
    flex: none;
}

.button-pill:hover {
    background: var(--primary-hover);
    color: #fff;
}

/* Store badges */
.store-badges {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    margin-top: 28px;
}

.store-badge {
    display: flex;
    align-items: center;
    gap: 8px;
    background: #000;
    color: #fff;
    text-decoration: none;
    padding: 8px 18px;
    border-radius: 10px;
    min-height: 48px;
}

.store-badge:hover {
    background: var(--inverse-surface);
    color: #fff;
}

.store-badge .mdi-apple {
    font-size: 26px;
}

.store-badge .mdi-google-play {
    font-size: 24px;
}

.store-badge-text {
    display: flex;
    flex-direction: column;
    line-height: 1.1;
    text-align: left;
}

.store-badge-text small {
    font-size: 10px;
}

.store-badge-text strong {
    font-size: 17px;
    font-weight: 600;
}

/* Shared type */
.eyebrow {
    font-family: var(--mono);
    font-size: 12px;
    color: var(--primary);
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.section-title {
    margin: 12px 0 0;
    font-size: clamp(30px, 3.6vw, 44px);
    line-height: 1.1;
    font-weight: 800;
    letter-spacing: -0.02em;
    text-wrap: balance;
}

.divider-label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
    font-weight: 500;
    color: var(--muted);
}

.divider-label::before,
.divider-label::after {
    content: '';
    flex: 1;
    height: 1px;
    background: var(--outline);
}

/* Itinerary icon tiles: set --c to an itinerary color */
.tile {
    width: var(--s, 28px);
    height: var(--s, 28px);
    flex: none;
    border-radius: 8px;
    border: 1px solid var(--c);
    background: color-mix(in srgb, var(--c) 13.3%, transparent);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--c);
}

.c-stay {
    --c: var(--stay);
}

.c-activity {
    --c: var(--activity);
}

.c-transport {
    --c: var(--transport);
}

.avatar {
    width: var(--s, 34px);
    height: var(--s, 34px);
    flex: none;
    border-radius: 50%;
    background: var(--bg-c, var(--primary));
    color: #fff;
    font-size: 12px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
}

.avatar-green {
    --bg-c: var(--transport);
}

.avatar-amber {
    --bg-c: var(--activity);
    color: var(--navy);
}

.avatar-empty {
    --bg-c: var(--border);
    color: var(--muted);
    font-size: 15px;
}

/* Hero */
.hero {
    max-width: var(--max);
    margin: 0 auto;
    padding: clamp(32px, 7vw, 88px) 20px clamp(40px, 6vw, 72px);
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: clamp(40px, 6vw, 80px);
}

.hero-copy {
    flex: 1 1 360px;
    max-width: 560px;
}

.hero-copy .divider-label {
    margin-bottom: 24px;
    max-width: 320px;
}

.hero h1 {
    margin: 0;
    font-size: clamp(42px, 6.4vw, 72px);
    line-height: 1.04;
    font-weight: 800;
    letter-spacing: -0.03em;
    text-wrap: balance;
}

.hero h1 .accent {
    color: var(--stay);
}

.hero-lead {
    margin: 20px 0 0;
    font-size: clamp(16px, 1.6vw, 19px);
    line-height: 1.55;
    color: var(--muted);
    text-wrap: pretty;
    max-width: 480px;
}

.hero-visual {
    flex: 1 1 300px;
    display: flex;
    justify-content: center;
}

/* Phone mockup */
.phone {
    width: 300px;
    height: 620px;
    background: var(--navy);
    border-radius: 44px;
    padding: 7px;
    box-shadow: 0 24px 60px rgb(27 42 66 / 0.22);
}

.phone-screen {
    height: 100%;
    background: var(--bg);
    border-radius: 37px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    line-height: 1.4;
}

.phone-status {
    display: flex;
    justify-content: space-between;
    padding: 14px 24px 4px;
    font-size: 12px;
    font-weight: 700;
}

.phone-status span:last-child {
    display: flex;
    gap: 3px;
}

.phone-appbar {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 16px;
}

.phone-appbar .mdi {
    font-size: 20px;
}

.phone-appbar strong {
    font-size: 16px;
    font-weight: 600;
    flex: 1;
}

.phone-tabs {
    display: flex;
    border-bottom: 1px solid var(--outline);
    font-size: 12px;
    font-weight: 600;
}

.phone-tabs span {
    flex: 1;
    text-align: center;
    padding: 9px 0;
    color: var(--muted);
}

.phone-tabs .active {
    color: var(--primary);
    border-bottom: 2px solid var(--primary);
}

.phone .divider-label {
    font-size: 10px;
    gap: 6px;
    margin: 4px 14px 8px;
}

.phone .divider-label:first-of-type {
    margin-top: 14px;
}

.timeline {
    display: grid;
    grid-template-columns: 60px 28px 1fr;
    gap: 10px;
    padding: 0 14px;
}

.timeline time {
    font-size: 9px;
    color: var(--muted);
    text-align: right;
    padding-top: 9px;
}

.timeline-rail {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.timeline-rail .tile {
    font-size: 15px;
}

.timeline-rail .tile .mdi {
    color: var(--c);
}

.timeline-rail::after {
    content: '';
    width: 2px;
    height: 32px;
    background: var(--c);
    margin-top: 4px;
}

.timeline-rail.last::after {
    display: none;
}

.timeline-item {
    padding-top: 4px;
}

.timeline-item strong {
    display: block;
    font-size: 12px;
    font-weight: 600;
}

.timeline-item span {
    display: block;
    font-size: 10px;
    color: var(--muted);
    margin-top: 2px;
}

/* How it works */
.band {
    background: var(--surface);
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
}

.how {
    max-width: var(--max);
    margin: 0 auto;
    padding: clamp(56px, 8vw, 104px) 20px;
    display: flex;
    flex-wrap: wrap;
    gap: clamp(32px, 6vw, 80px);
}

.how-intro {
    flex: 1 1 280px;
    max-width: 400px;
}

.how-intro p {
    margin: 16px 0 0;
    font-size: 16px;
    line-height: 1.55;
    color: var(--muted);
    text-wrap: pretty;
}

.steps {
    flex: 2 1 420px;
    display: grid;
    grid-template-columns: 44px minmax(0, 1fr);
    column-gap: 20px;
}

.step-rail {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.step-rail .tile {
    --s: 44px;
    font-size: 24px;
}

.step-rail::after {
    content: '';
    width: 2px;
    flex: 1;
    background: var(--c);
    margin: 6px 0;
}

.step-rail.last::after {
    display: none;
}

.step {
    padding: 4px 0 44px;
}

.step.last {
    padding-bottom: 0;
}

.step-label {
    font-family: var(--mono);
    font-size: 11px;
    color: var(--c);
}

/* The app amber is too light for small text on white; darken it for the label only. */
.step.c-activity .step-label {
    color: color-mix(in srgb, var(--activity) 65%, #000);
}

.step h3 {
    font-weight: 700;
    font-size: 22px;
    margin: 4px 0 0;
    line-height: 1.3;
}

.step p {
    font-size: 15px;
    line-height: 1.55;
    color: var(--muted);
    margin: 6px 0 0;
}

.avatars {
    display: flex;
    margin-top: 14px;
}

.avatars .avatar {
    box-shadow: 0 0 0 2px var(--surface);
}

.avatars .avatar + .avatar {
    margin-left: -6px;
}

.email-strip {
    margin-top: 14px;
    background: var(--primary);
    border-radius: 8px;
    padding: 14px;
    color: #fff;
    max-width: 360px;
    box-shadow: 0 2px 8px rgb(0 0 0 / 0.08);
}

.email-strip > div:first-child {
    font-size: 12px;
    opacity: 0.9;
    margin-bottom: 8px;
}

.email-pill {
    display: flex;
    align-items: center;
    gap: 8px;
    border: 1px solid rgb(255 255 255 / 0.5);
    border-radius: 9999px;
    padding: 8px 14px;
    font-family: var(--mono);
    font-size: 12px;
    overflow: hidden;
    white-space: nowrap;
}

/* Features */
.features {
    max-width: var(--max);
    margin: 0 auto;
    padding: clamp(56px, 8vw, 104px) 20px;
    display: flex;
    flex-direction: column;
    gap: clamp(56px, 8vw, 96px);
}

.features-head {
    max-width: 560px;
}

.feature {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: clamp(28px, 5vw, 72px);
}

.feature-copy {
    flex: 1 1 320px;
    max-width: 460px;
}

.feature-copy > .mdi {
    font-size: 28px;
}

.feature-copy h3 {
    margin: 10px 0 0;
    font-size: clamp(22px, 2.4vw, 28px);
    font-weight: 700;
    line-height: 1.2;
}

.feature-copy p {
    margin: 10px 0 0;
    font-size: 16px;
    line-height: 1.6;
    color: var(--muted);
    text-wrap: pretty;
}

.feature-visual {
    flex: 1 1 320px;
    display: flex;
    justify-content: center;
}

.feature-stack {
    width: 100%;
    max-width: 400px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    line-height: 1.5;
}

.panel {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
}

.members {
    width: 100%;
    max-width: 400px;
    overflow: hidden;
    line-height: 1.4;
}

.members-head {
    padding: 12px 16px;
    font-size: 11px;
    font-weight: 700;
    color: var(--primary);
    letter-spacing: 0.06em;
    text-transform: uppercase;
    border-bottom: 1px solid var(--border);
}

.member {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
}

.member .avatar {
    --s: 36px;
    font-size: 13px;
}

.member strong {
    display: block;
    font-size: 14px;
    font-weight: 600;
}

.member div span {
    font-size: 12px;
    color: var(--muted);
}

.snackbar {
    margin: 4px 12px 12px;
    background: var(--inverse-surface);
    color: #f0f0f7;
    border-radius: 8px;
    padding: 12px 14px;
    font-size: 13px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.snackbar .mdi {
    font-size: 18px;
    color: #aac7ff;
}

.email-preview {
    padding: 14px 16px;
    font-size: 13px;
    color: var(--muted);
}

.email-preview b {
    color: var(--text);
}

.email-preview .mono {
    font-family: var(--mono);
    font-size: 12px;
}

.email-preview .line {
    height: 6px;
    background: var(--border);
    border-radius: 3px;
    margin-top: 12px;
    width: 90%;
}

.email-preview .line + .line {
    margin-top: 6px;
    width: 70%;
}

.arrow-down {
    display: flex;
    justify-content: center;
    font-size: 20px;
    color: var(--subtle);
}

.item-row {
    padding: 12px 16px;
    display: flex;
    gap: 12px;
    align-items: center;
}

.item-row .tile {
    --s: 30px;
    font-size: 16px;
}

.item-row strong {
    display: block;
    font-size: 14px;
    font-weight: 600;
}

.item-row span {
    font-size: 12px;
    color: var(--muted);
}

.category {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 16px;
}

.category .tile {
    --s: 36px;
    font-size: 20px;
}

.category > div:nth-child(2) {
    flex: 1;
}

.category strong {
    display: block;
    font-size: 15px;
    font-weight: 600;
}

.category span {
    font-size: 12px;
    color: var(--muted);
}

.category::after {
    content: '';
    width: 4px;
    height: 36px;
    border-radius: 2px;
    background: var(--c);
}

/* Get the app */
.get {
    background: var(--navy);
    color: #fff;
}

.get .container {
    padding-top: clamp(64px, 9vw, 112px);
    padding-bottom: clamp(64px, 9vw, 112px);
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 20px;
}

.get img {
    width: 64px;
    height: 64px;
    border-radius: 14px;
    box-shadow: 0 0 0 1px rgb(255 255 255 / 0.18);
}

.get h2 {
    margin: 0;
    font-size: clamp(32px, 4.4vw, 52px);
    line-height: 1.08;
    font-weight: 800;
    letter-spacing: -0.02em;
    text-wrap: balance;
    max-width: 720px;
}

.get p {
    margin: 0;
    font-size: 17px;
    line-height: 1.55;
    color: var(--primary-container);
    max-width: 480px;
}

.get .store-badges {
    justify-content: center;
    margin-top: 8px;
}

.get .store-badge {
    box-shadow: 0 0 0 1px rgb(255 255 255 / 0.3);
}

/* Footer */
.site-footer {
    background: var(--navy);
    color: var(--outline);
}

.get + .site-footer {
    border-top: 1px solid rgb(255 255 255 / 0.1);
}

.site-footer .container {
    padding-top: 28px;
    padding-bottom: 36px;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

.footer-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 13px;
}

.footer-brand img {
    width: 24px;
    height: 24px;
    border-radius: 6px;
}

.footer-links {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 24px;
    font-size: 14px;
}

.footer-links a {
    color: var(--outline);
    text-decoration: none;
}

.footer-links a:hover {
    color: #fff;
}

/* Prose pages (legal + help) */
.page-header {
    padding: clamp(32px, 6vw, 64px) 0 24px;
}

.page-header h1 {
    margin: 8px 0 0;
    font-size: clamp(34px, 5vw, 52px);
    line-height: 1.08;
    font-weight: 800;
    letter-spacing: -0.02em;
}

.page-header p {
    margin: 14px 0 0;
    color: var(--muted);
    font-size: 17px;
    max-width: 640px;
}

.prose {
    max-width: var(--prose);
    padding-bottom: 80px;
}

.prose h2 {
    font-size: 24px;
    font-weight: 700;
    line-height: 1.25;
    margin: 2em 0 0.5em;
}

.prose h3 {
    font-size: 18px;
    font-weight: 700;
    margin: 1.6em 0 0.4em;
}

.prose p,
.prose li {
    color: #2c2f35;
}

.prose li + li {
    margin-top: 0.35em;
}

.prose table {
    width: 100%;
    border-collapse: collapse;
    margin: 1.2em 0;
    font-size: 15px;
    display: block;
    overflow-x: auto;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
}

.prose th,
.prose td {
    text-align: left;
    padding: 10px 14px;
    border-bottom: 1px solid var(--border);
    vertical-align: top;
}

.prose tr:last-child td {
    border-bottom: 0;
}

.prose th {
    font-weight: 600;
}

.notice {
    border: 1px solid var(--border);
    border-left: 4px solid var(--activity);
    background: var(--surface);
    border-radius: var(--radius);
    padding: 14px 16px;
    margin: 1.2em 0;
}

.notice p {
    margin: 0;
}

.code-block {
    position: relative;
    margin: 1em 0;
}

.code-block pre {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 16px 72px 16px 16px;
    overflow-x: auto;
    margin: 0;
    line-height: 1.5;
}

.copy-button {
    position: absolute;
    top: 8px;
    right: 8px;
    font: inherit;
    font-size: 12px;
    font-weight: 600;
    padding: 4px 10px;
    border-radius: 9999px;
    border: 1px solid var(--border);
    background: var(--bg);
    color: var(--primary);
    cursor: pointer;
}

.copy-button:hover {
    border-color: var(--primary);
}

.breadcrumbs a {
    font-family: var(--mono);
    font-size: 12px;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    text-decoration: none;
}

.help-layout {
    display: grid;
    grid-template-columns: 220px 1fr;
    gap: 48px;
}

.help-layout > * {
    min-width: 0;
}

.help-sidebar {
    position: sticky;
    top: 88px;
    align-self: start;
    font-size: 15px;
}

.help-sidebar h3 {
    font-family: var(--mono);
    font-weight: 400;
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: var(--muted);
    margin: 0 0 4px;
}

.help-sidebar ul {
    list-style: none;
    padding: 0;
    margin: 0 0 24px;
}

.help-sidebar a {
    display: block;
    padding: 6px 0 6px 12px;
    border-left: 2px solid var(--border);
    color: var(--text);
    text-decoration: none;
}

.help-sidebar a:hover {
    color: var(--primary);
}

.help-sidebar a[aria-current='page'] {
    color: var(--primary);
    border-left-color: var(--primary);
    font-weight: 600;
}

@media (max-width: 860px) {
    .help-layout {
        grid-template-columns: 1fr;
        gap: 0;
    }

    .help-sidebar {
        position: static;
        border-bottom: 1px solid var(--border);
        margin-bottom: 24px;
    }
}

/* Help center index */
.help-section {
    padding-bottom: 48px;
}

.help-section h2 {
    font-size: 22px;
    font-weight: 700;
    margin: 0 0 16px;
}

.card-grid {
    display: grid;
    gap: 16px;
    grid-template-columns: repeat(auto-fill, minmax(min(100%, 280px), 1fr));
}

.card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 20px;
    display: flex;
    gap: 14px;
    align-items: flex-start;
}

a.card {
    color: inherit;
    text-decoration: none;
}

a.card:hover {
    border-color: var(--primary);
}

.card .tile {
    --s: 40px;
    font-size: 22px;
}

.card h3 {
    margin: 0;
    font-size: 16px;
    font-weight: 600;
    line-height: 1.35;
}

.card p {
    margin: 4px 0 0;
    font-size: 14px;
    color: var(--muted);
}

.badge {
    display: inline-block;
    font-family: var(--mono);
    font-size: 10px;
    font-weight: 400;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    padding: 2px 8px;
    border-radius: 9999px;
    background: var(--border);
    color: var(--muted);
    margin-left: 6px;
    vertical-align: middle;
}

.not-found {
    padding: clamp(64px, 12vw, 140px) 0;
}

.not-found .store-badges {
    margin-top: 28px;
}
