:root {
    color-scheme: light;
    --ink: #172235;
    --muted: #4b5767;
    --paper: #faf8f2;
    --line: #e4dfd5;
    --gold: #795018;
    --display: "Playfair Display", Georgia, serif;
    --body: "DM Sans", system-ui, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-padding-top: 28px; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 16px/1.5 var(--body); }
a { color: inherit; text-decoration: none; }
button, input { font: inherit; }
button, summary { cursor: pointer; }
img { display: block; max-width: 100%; }
[hidden] { display: none !important; }
:focus-visible { outline: 3px solid #986422; outline-offset: 4px; }
.wrap { width: min(calc(100% - 80px), 1176px); margin-inline: auto; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }

.site-header { border-bottom: 1px solid var(--line); }
.header-row {
    min-height: 80px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 26px;
}
.brand { display: inline-flex; align-items: center; gap: 9px; font-size: 20px; font-weight: 800; letter-spacing: -.045em; white-space: nowrap; }
.brand img { object-fit: contain; flex-shrink: 0; }
.site-nav, .header-actions { display: flex; align-items: center; gap: 26px; font-size: .9rem; font-weight: 700; }
.site-nav a:hover, .login-link:hover, .footer-row a:not(.brand):hover { color: var(--gold); }
.button {
    min-height: 50px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 10px 22px;
    border-radius: 10px;
    background: #1b2a40;
    color: #fff;
    font-weight: 800;
    white-space: nowrap;
}
.button:hover { background: #293d58; }
.button-small { min-height: 42px; padding: 8px 16px; }
.text-link { display: inline-flex; align-items: center; gap: .65em; font-weight: 800; color: var(--ink); }
.text-link:hover { color: var(--gold); }
.text-link span { font-size: 1.2em; line-height: 1; }

.hero { border-bottom: 1px solid var(--line); overflow: hidden; }
.hero-grid {
    display: grid;
    grid-template-columns: minmax(0,1.05fr) minmax(0,1fr);
    align-items: center;
    gap: 14px;
    min-height: 660px;
    padding-block: 58px 64px;
}
.hero-copy { position: relative; z-index: 1; }
.section-label { margin: 0 0 12px; color: var(--gold); font-size: .76rem; letter-spacing: .14em; text-transform: uppercase; font-weight: 800; }
h1,h2,h3 { margin: 0; font: 600 2rem/1.1 var(--display); letter-spacing: -.045em; text-wrap: balance; }
h1 { font-size: clamp(3.2rem,6vw,5.85rem); line-height: 1; }
h2 { font-size: clamp(2.15rem,4.2vw,3.6rem); }
.hero .lead { max-width: 440px; margin: 23px 0 24px; color: var(--muted); font-size: clamp(1rem,1.7vw,1.2rem); }
.search {
    display: flex;
    max-width: 460px;
    padding: 5px;
    background: #fffefa;
    border: 1px solid #d8d2c5;
    border-radius: 11px;
}
.search input { flex: 1; width: 100%; min-width: 0; border: 0; padding: 9px 12px; background: transparent; color: var(--ink); }
.search input::placeholder { color: #606773; }
.search button { border: 0; border-radius: 7px; padding: 8px 16px; color: #472b08; background: #f2e2c6; font-weight: 800; }
.search button:hover { background: #ead2aa; }
.hero-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 20px; margin-top: 20px; }

.hero-art {
    min-height: 530px;
    position: relative;
    display: grid;
    place-items: center;
    isolation: isolate;
}
.hero-art::before {
    content: "";
    position: absolute;
    inset: 3% 0;
    z-index: -1;
    background: radial-gradient(ellipse at 56% 47%, #f0debd 0, #f6ebd4 45%, transparent 71%);
}
.phone {
    --edge: 7px;
    position: relative;
    width: 246px;
    padding: 19px var(--edge) 7px;
    border: 2px solid #5d6168;
    border-radius: 38px;
    background: #11151c;
    box-shadow: inset 0 0 0 2px #272d36, 0 30px 55px -25px #311b0d82, 0 11px 16px -8px #1b253445;
}
.phone::before {
    content: "";
    position: absolute;
    z-index: 1;
    top: 7px;
    left: 50%;
    width: 29%;
    height: 8px;
    transform: translateX(-50%);
    border-radius: 18px;
    background: #05070a;
    box-shadow: inset -5px -1px 2px #1a2231;
}
.phone img { width: 100%; height: auto; border-radius: 25px 25px 29px 29px; background: #f6f8fb; }
.phone-front { position: absolute; left: 14%; top: 0; width: clamp(208px, 21vw, 262px); transform: rotate(-7deg); z-index: 1; }
.phone-behind { position: absolute; right: 5%; top: 9%; width: clamp(183px, 19vw, 237px); transform: rotate(11deg); }

.showcase { padding-block: 86px 82px; }
.showcase-intro { text-align: center; margin-bottom: 24px; }
.screen-menu { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin-bottom: 30px; }
.screen-menu a {
    border: 1px solid var(--line);
    border-radius: 99px;
    padding: 9px 15px;
    font-size: .88rem;
    font-weight: 800;
    background: #fffdf8;
}
.screen-menu a:hover { border-color: #9d7c45; }
.screen-menu a[aria-current="true"] { border-color: #26354a; color: #fff; background: #26354a; }
.screen-panel {
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: center;
    overflow: hidden;
    min-height: 550px;
    border: 1px solid var(--line);
    border-radius: 24px;
    background: #fffdf9;
}
.screen-panel + .screen-panel { margin-top: 24px; }
.screen-panel[hidden] + .screen-panel { margin-top: 0; }
.screen-art {
    min-height: 100%;
    display: grid;
    place-items: center;
    padding: 24px;
    background: radial-gradient(ellipse at center, #f9eed8, #eae3d6);
}
.screen-art .phone { width: 222px; }
.screen-copy { padding: clamp(26px,6vw,84px); }
.screen-copy h3 { font-size: clamp(2rem,4vw,3.6rem); }
.screen-copy > p:not(.section-label) { max-width: 350px; margin: 16px 0 23px; color: var(--muted); font-size: 1.05rem; }

.workflow { border-block: 1px solid var(--line); background: #f3efe4; }
.workflow-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); }
.workflow-grid > div { padding: 43px min(5vw,64px) 45px 0; }
.workflow-grid > div + div { padding-right: 0; padding-left: min(5vw,64px); border-left: 1px solid #ddd5c4; }
.workflow h2 { font-size: clamp(1.85rem,3.15vw,2.85rem); }
.workflow p { max-width: 375px; color: var(--muted); margin: 12px 0 15px; }

.install { padding-block: 70px; }
.install-card {
    display: grid;
    grid-template-columns: 82px 1fr auto;
    align-items: center;
    gap: 24px;
    background: #e9ecf1;
    border: 1px solid #dce1ea;
    padding: clamp(20px,5vw,45px);
    border-radius: 21px;
}
.install-card img, .dialog-header img { border-radius: 20%; }
.install-card h2 { font-size: clamp(1.75rem,3.4vw,2.9rem); }
.install-card p { color: var(--muted); margin: 8px 0 0; }
.install-help { margin-top: 18px; border-bottom: 1px solid var(--line); padding: 0 0 14px; }
.install-help summary { width: fit-content; font-weight: 800; }
.install-help p { max-width: 680px; color: var(--muted); }
.install-dialog {
    width: min(calc(100% - 28px),440px);
    max-height: calc(100dvh - 28px);
    border: 1px solid var(--line);
    border-radius: 19px;
    color: var(--ink);
    background: #fffdf8;
    padding: 23px;
    box-shadow: 0 18px 70px #0b142b50;
}
.install-dialog::backdrop { background: #1420347f; }
.dialog-header { display: grid; grid-template-columns: 56px 1fr auto; align-items: center; gap: 10px; }
.dialog-header h2 { font-size: clamp(1.2rem,4.7vw,1.5rem); }
.dialog-header button { border: 0; width: 40px; height: 40px; border-radius: 8px; background: #efeae0; color: var(--ink); font-size: 1.5rem; }
.install-dialog li + li { margin-top: 6px; }
.install-dialog .text-link { margin-top: 8px; }
footer { border-top: 1px solid var(--line); }
.footer-row { min-height: 95px; display: flex; gap: 15px; justify-content: space-between; align-items: center; color: var(--muted); font-size: .86rem; }
.footer-row .brand { color: var(--ink); }

@media (max-width: 990px) {
    .wrap { width: min(calc(100% - 48px), 1176px); }
    .site-nav { gap: 14px; }
    .hero-grid { gap: 6px; min-height: 550px; }
    .hero-art { min-height: 470px; }
    .phone-front { left: 6%; }
    .phone-behind { right: 4%; }
}
@media (max-width: 780px) {
    .site-nav { display: none; }
    .header-row { min-height: 65px; }
    .hero-grid { grid-template-columns: 1fr; padding-block: 38px 37px; gap: 20px; }
    .hero-copy { max-width: 600px; }
    .hero-art { min-height: clamp(405px, 75vw, 535px); width: min(100%, 530px); margin-inline: auto; }
    .phone-front { left: 15%; width: clamp(172px, 40vw, 228px); }
    .phone-behind { right: 12%; width: clamp(150px, 35vw, 204px); top: 10%; }
    .hero-break { display: none; }
    .showcase { padding-block: 55px; }
    .screen-panel { min-height: 0; }
    .screen-art .phone { width: min(100%, 192px); }
}
@media (max-width: 560px) {
    .wrap { width: calc(100% - 36px); }
    .header-row { gap: 9px; }
    .brand { gap: 4px; font-size: 18px; }
    .site-header .brand img { width: 34px; height: 34px; }
    .header-actions { gap: 10px; font-size: .82rem; }
    .button-small { min-height: 36px; padding: 6px 11px; }
    h1 { font-size: clamp(2.55rem,12vw,4rem); }
    .hero .lead { margin-top: 16px; }
    .hero-actions { gap: 14px; }
    .hero-actions .button { min-height: 45px; padding-inline: 15px; }
    .hero-actions .text-link { font-size: .9rem; }
    .phone-front { left: 12%; }
    .phone-behind { right: 9%; }
    .screen-panel { grid-template-columns: 1fr; }
    .screen-copy { grid-row: 1; padding: 24px; }
    .screen-art { padding-block: 20px; }
    .screen-menu { justify-content: start; }
    .screen-menu a { padding: 7px 11px; }
    .workflow-grid { grid-template-columns: 1fr; }
    .workflow-grid > div { padding: 32px 0; }
    .workflow-grid > div + div { padding-left: 0; border-left: 0; border-top: 1px solid #ddd5c4; }
    .install { padding-block: 46px; }
    .install-card { grid-template-columns: 54px 1fr; gap: 12px; }
    .install-card img { width: 54px; height: 54px; }
    .install-card .button { grid-column: 1/-1; }
    .footer-row { flex-direction: column; justify-content: center; align-items: flex-start; padding-block: 18px; gap: 9px; }
}
