@import url('https://fonts.googleapis.com/css2?family=Manrope:wght@500;700;800&family=Unbounded:wght@600;800&display=swap');

* {
    box-sizing: border-box;
}

:root {
    --ink: #080808;
    --ink-2: #171717;
    --paper: #fff7e8;
    --white: #ffffff;
    --line: rgba(8, 8, 8, 0.14);
    --muted: #6e6256;
    --yellow: #ffd400;
    --red: #ff2d22;
    --orange: #ff7a1a;
    --green: #10a85a;
    --shadow: 0 24px 70px rgba(8, 8, 8, 0.18);
    --radius: 8px;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: 'Manrope', sans-serif;
    background: var(--ink);
    color: var(--ink);
    line-height: 1.45;
    -webkit-font-smoothing: antialiased;
}

button,
input,
textarea,
select {
    font: inherit;
}

button {
    cursor: pointer;
}

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

code {
    padding: 2px 6px;
    background: rgba(255, 212, 0, 0.22);
}

.loader {
    position: fixed;
    inset: 0;
    z-index: 20;
    display: grid;
    place-items: center;
    background: var(--ink);
    color: var(--yellow);
}

.loader-mark {
    width: 88px;
    height: 88px;
    display: grid;
    place-items: center;
    border: 2px solid var(--yellow);
    border-radius: var(--radius);
    font-family: 'Unbounded', sans-serif;
    font-size: 44px;
    animation: pulse 1.1s ease-in-out infinite alternate;
}

@keyframes pulse {
    from { transform: scale(0.96); opacity: 0.7; }
    to { transform: scale(1); opacity: 1; }
}

.app-shell {
    min-height: 100vh;
    background:
        linear-gradient(180deg, var(--ink) 0 560px, var(--paper) 560px 100%),
        var(--paper);
}

.topbar {
    position: sticky;
    top: 0;
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 14px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.18);
    background: rgba(8, 8, 8, 0.9);
    backdrop-filter: blur(16px);
}

.brand,
.cart-button {
    border: 0;
    background: transparent;
}

.brand {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 0;
    color: var(--white);
    text-align: left;
}

.brand-mark {
    width: 42px;
    height: 42px;
    display: grid;
    place-items: center;
    border-radius: var(--radius);
    background: var(--yellow);
    color: var(--ink);
    font-family: 'Unbounded', sans-serif;
    font-size: 15px;
    font-weight: 800;
}

.brand strong,
.brand small {
    display: block;
}

.brand strong {
    font-size: 14px;
}

.brand small {
    color: rgba(255, 255, 255, 0.62);
    font-size: 11px;
    text-transform: uppercase;
}

.cart-button {
    min-width: 90px;
    height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 0 8px 0 14px;
    border: 1px solid rgba(255, 255, 255, 0.28);
    border-radius: var(--radius);
    color: var(--white);
}

.cart-button strong {
    min-width: 26px;
    height: 26px;
    display: grid;
    place-items: center;
    border-radius: 6px;
    background: var(--red);
    color: var(--white);
    font-size: 12px;
}

.screen {
    padding: 14px;
}

.screen-home {
    padding-top: 0;
}

.hero {
    min-height: calc(100vh - 70px);
    display: grid;
    grid-template-rows: auto 1fr;
    gap: 24px;
    padding: 30px 0 22px;
    color: var(--white);
}

.hero-copy {
    max-width: 800px;
}

.eyebrow {
    margin: 0 0 12px;
    color: var(--orange);
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

h1,
h2,
h3,
p {
    margin-top: 0;
}

h1,
h2,
h3 {
    letter-spacing: 0;
}

.hero h1 {
    max-width: 950px;
    margin-bottom: 18px;
    font-family: 'Unbounded', sans-serif;
    font-size: clamp(39px, 10.4vw, 104px);
    line-height: 0.92;
    text-wrap: balance;
}

.hero-lead {
    max-width: 680px;
    margin-bottom: 0;
    color: rgba(255, 255, 255, 0.78);
    font-size: 18px;
}

.hero-actions,
.success-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-top: 22px;
}

.action-primary,
.action-ghost {
    min-height: 52px;
    border: 1px solid var(--ink);
    border-radius: var(--radius);
    padding: 0 18px;
    font-weight: 800;
}

.action-primary {
    background: var(--red);
    color: var(--white);
}

.action-ghost {
    background: var(--white);
    color: var(--ink);
}

.action-primary:active,
.action-ghost:active,
.product-card:active,
.back-btn:active {
    transform: translateY(2px);
}

.full {
    width: 100%;
}

.phone-stage {
    position: relative;
    min-height: 300px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: var(--radius);
    background:
        linear-gradient(135deg, rgba(255, 45, 34, 0.95), rgba(255, 122, 26, 0.92)),
        var(--red);
    box-shadow: var(--shadow);
}

.phone-stage::before {
    content: '';
    position: absolute;
    inset: 18px;
    border: 1px solid rgba(255, 255, 255, 0.38);
    border-radius: var(--radius);
}

.phone-card {
    position: absolute;
    width: min(72%, 340px);
    padding: 18px;
    border: 1px solid var(--ink);
    border-radius: var(--radius);
    background: var(--white);
    color: var(--ink);
    box-shadow: 10px 10px 0 var(--yellow);
}

.phone-card span,
.phone-card strong {
    display: block;
}

.phone-card span {
    color: var(--muted);
    font-size: 12px;
    text-transform: uppercase;
}

.phone-card strong {
    margin-top: 8px;
    font-family: 'Unbounded', sans-serif;
    font-size: 24px;
}

.card-one {
    top: 32px;
    left: 24px;
}

.card-two {
    top: 120px;
    right: 20px;
    background: var(--yellow);
}

.card-three {
    bottom: 28px;
    left: 44px;
    background: var(--ink);
    color: var(--white);
}

.card-three span {
    color: rgba(255, 255, 255, 0.62);
}

.capabilities {
    display: grid;
    gap: 10px;
    margin: 0 0 34px;
}

.capabilities article,
.product-card,
.detail-card,
.payment-card,
.form-card,
.checkout-summary,
.cart-summary,
.empty-card,
.order-card,
.loading-card {
    border: 1px solid var(--ink);
    border-radius: var(--radius);
    background: var(--white);
}

.capabilities article {
    padding: 20px;
}

.capabilities span {
    display: inline-block;
    margin-bottom: 28px;
    font-family: 'Unbounded', sans-serif;
    color: var(--red);
}

.capabilities h2,
.section-title h2 {
    font-family: 'Unbounded', sans-serif;
    font-size: clamp(25px, 7vw, 54px);
    line-height: 1;
}

.capabilities p,
.product-card p,
.detail-card p,
.payment-card p,
.empty-card p {
    color: var(--muted);
}

.catalog-block {
    padding-bottom: 30px;
}

.section-title {
    margin-bottom: 18px;
}

.categories {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding: 0 0 14px;
    scrollbar-width: none;
}

.categories::-webkit-scrollbar {
    display: none;
}

.category-btn {
    flex: 0 0 auto;
    min-height: 42px;
    padding: 0 13px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: var(--white);
    color: var(--ink);
}

.category-btn.active {
    border-color: var(--ink);
    background: var(--yellow);
}

.products-grid {
    display: grid;
    gap: 12px;
}

.product-card {
    overflow: hidden;
    min-height: 372px;
    display: grid;
    grid-template-rows: 190px 1fr;
    box-shadow: 0 10px 0 rgba(8, 8, 8, 0.06);
}

.product-photo,
.detail-photo {
    position: relative;
    overflow: hidden;
    background: var(--ink);
}

.product-photo img,
.detail-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.product-badge,
.detail-photo span {
    position: absolute;
    top: 12px;
    left: 12px;
    padding: 7px 10px;
    border-radius: 999px;
    background: var(--yellow);
    color: var(--ink);
    font-size: 12px;
    font-weight: 800;
}

.product-price {
    position: absolute;
    right: 12px;
    bottom: 12px;
    padding: 8px 10px;
    border-radius: var(--radius);
    background: var(--ink);
    color: var(--white);
    font-weight: 800;
}

.product-body {
    display: grid;
    align-content: start;
    padding: 16px;
}

.product-meta {
    margin-bottom: 10px;
    font-size: 12px;
    font-weight: 800;
    text-transform: uppercase;
}

.product-card h3 {
    margin-bottom: 10px;
    font-family: 'Unbounded', sans-serif;
    font-size: 24px;
    line-height: 1.04;
}

.product-bullets {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 14px;
}

.product-bullets span {
    padding: 6px 8px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: rgba(255, 212, 0, 0.18);
    font-size: 12px;
    font-weight: 800;
}

.accent-red .product-badge,
.accent-red.detail-card .detail-photo span {
    background: var(--red);
    color: var(--white);
}

.accent-orange .product-badge,
.accent-orange.detail-card .detail-photo span {
    background: var(--orange);
    color: var(--ink);
}

.accent-green .product-badge,
.accent-green.detail-card .detail-photo span {
    background: var(--green);
    color: var(--white);
}

.accent-black .product-badge,
.accent-black.detail-card .detail-photo span {
    background: var(--ink);
    color: var(--yellow);
}

.section-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 14px;
}

.section-header h2 {
    font-family: 'Unbounded', sans-serif;
    font-size: 22px;
}

.back-btn {
    width: 42px;
    height: 42px;
    border: 1px solid var(--ink);
    border-radius: var(--radius);
    background: var(--white);
    color: var(--ink);
    font-size: 22px;
}

.screen-detail,
.payment-screen,
.success-screen {
    background: var(--paper);
}

.detail-card {
    overflow: hidden;
}

.detail-layout {
    display: grid;
}

.detail-photo {
    min-height: 290px;
}

.detail-copy {
    padding: 20px;
}

.detail-card h1 {
    margin-bottom: 16px;
    font-family: 'Unbounded', sans-serif;
    font-size: clamp(34px, 9vw, 76px);
    line-height: 0.95;
}

.detail-card > p:not(.eyebrow),
.detail-copy > p:not(.eyebrow) {
    font-size: 17px;
}

.detail-bullets {
    display: grid;
    gap: 10px;
    margin: 22px 0;
}

.detail-bullets div {
    display: flex;
    gap: 10px;
    padding: 12px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
}

.detail-bullets span {
    color: var(--red);
    font-weight: 800;
}

.detail-price,
.summary-lines > div,
.checkout-summary > div,
.success-details > div {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    padding: 12px 0;
    border-top: 1px solid var(--line);
}

.detail-price {
    margin-bottom: 18px;
}

.detail-price strong,
.summary-total strong,
.payment-total {
    font-family: 'Unbounded', sans-serif;
}

.cart-container,
.checkout-container,
.orders-list {
    display: grid;
    gap: 12px;
}

.cart-items {
    display: grid;
    gap: 10px;
}

.cart-item {
    display: grid;
    grid-template-columns: 66px 1fr auto;
    gap: 12px;
    align-items: center;
    padding: 12px;
    border: 1px solid var(--ink);
    border-radius: var(--radius);
    background: var(--white);
}

.cart-item img {
    width: 66px;
    height: 66px;
    border-radius: var(--radius);
    object-fit: cover;
}

.cart-item h3 {
    margin-bottom: 4px;
    font-size: 15px;
}

.cart-item p {
    margin: 0;
    color: var(--muted);
    font-size: 13px;
}

.qty-control {
    display: flex;
    align-items: center;
    gap: 8px;
}

.qty-control button {
    width: 32px;
    height: 32px;
    border: 1px solid var(--ink);
    border-radius: var(--radius);
    background: var(--paper);
    font-weight: 800;
}

.cart-summary,
.checkout-summary,
.form-card,
.payment-card,
.empty-card,
.loading-card {
    padding: 18px;
}

.summary-total {
    margin-top: 10px;
    border-top: 2px solid var(--ink) !important;
    font-size: 18px;
}

.cart-order-form {
    display: grid;
    gap: 12px;
    margin-top: 16px;
}

.fulfillment-toggle {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
}

.fulfillment-toggle button {
    min-height: 72px;
    display: grid;
    align-content: center;
    gap: 4px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: var(--white);
    text-align: left;
    padding: 12px;
}

.fulfillment-toggle button.active {
    border-color: var(--ink);
    background: var(--yellow);
}

.fulfillment-toggle span,
.fulfillment-toggle strong {
    display: block;
}

.fulfillment-toggle span {
    font-weight: 800;
}

.fulfillment-toggle strong {
    color: var(--muted);
    font-size: 12px;
}

.form-grid {
    display: grid;
    gap: 12px;
}

label {
    display: grid;
    gap: 7px;
    margin-bottom: 0;
    color: var(--muted);
    font-size: 13px;
    font-weight: 800;
    text-transform: uppercase;
}

input,
textarea,
select {
    width: 100%;
    border: 1px solid var(--ink);
    border-radius: var(--radius);
    background: var(--white);
    color: var(--ink);
    padding: 14px;
    text-transform: none;
}

input[readonly] {
    background: rgba(8, 8, 8, 0.05);
}

textarea {
    min-height: 88px;
    resize: vertical;
}

input:focus,
textarea:focus,
select:focus {
    outline: 3px solid rgba(255, 212, 0, 0.68);
}

.phone-row {
    display: grid;
    grid-template-columns: 1fr 76px;
    gap: 8px;
}

.phone-row button {
    border: 1px solid var(--ink);
    border-radius: var(--radius);
    background: var(--yellow);
    font-weight: 800;
}

.payment-card {
    min-height: 420px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.payment-card h1,
.success-hero h2 {
    margin-bottom: 18px;
    font-family: 'Unbounded', sans-serif;
    font-size: clamp(30px, 8vw, 58px);
    line-height: 1;
}

.payment-total {
    margin: 26px 0;
    font-size: 42px;
}

.success-screen {
    min-height: calc(100vh - 70px);
}

.success-hero {
    padding: 28px 0;
}

.success-icon {
    width: 86px;
    height: 86px;
    display: grid;
    place-items: center;
    margin-bottom: 24px;
    border: 1px solid var(--ink);
    border-radius: var(--radius);
    background: var(--yellow);
    color: var(--ink);
    font-family: 'Unbounded', sans-serif;
    font-size: 46px;
    font-weight: 800;
}

.success-details {
    border: 1px solid var(--ink);
    border-radius: var(--radius);
    background: var(--white);
    padding: 4px 18px;
}

.order-card {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 12px;
    padding: 16px;
}

.order-card button {
    grid-column: 1 / -1;
}

.toast {
    position: fixed;
    left: 14px;
    right: 14px;
    bottom: 18px;
    z-index: 30;
    padding: 14px 16px;
    border-radius: var(--radius);
    background: var(--ink);
    color: var(--white);
    box-shadow: var(--shadow);
}

@media (max-width: 420px) {
    .hero-actions,
    .success-actions,
    .fulfillment-toggle {
        grid-template-columns: 1fr;
    }

    .cart-item {
        grid-template-columns: 58px 1fr;
    }

    .cart-item img {
        width: 58px;
        height: 58px;
    }

    .qty-control {
        grid-column: 2;
        justify-self: start;
    }
}

@media (min-width: 760px) {
    .screen,
    .topbar {
        padding-left: max(24px, calc((100vw - 1160px) / 2));
        padding-right: max(24px, calc((100vw - 1160px) / 2));
    }

    .hero {
        grid-template-columns: minmax(0, 1.12fr) minmax(320px, 0.88fr);
        grid-template-rows: none;
        align-items: center;
    }

    .capabilities,
    .products-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .cart-container {
        grid-template-columns: minmax(0, 1.05fr) minmax(360px, 0.95fr);
        align-items: start;
    }

    .cart-summary {
        position: sticky;
        top: 88px;
    }

    .form-grid {
        grid-template-columns: 1fr 1fr;
    }

    .detail-layout {
        grid-template-columns: minmax(320px, 0.9fr) minmax(0, 1.1fr);
    }

    .detail-photo {
        min-height: 580px;
    }
}
