:root {
    --account-ink: #151513;
    --account-muted: #65655f;
    --account-paper: #ffffff;
    --account-canvas: #f5f5f2;
    --account-line: #deded8;
    --account-green: #155b45;
    --account-green-dark: #0d4433;
    --account-coral: #e75f42;
    --account-soft-green: #e9f3ee;
    --account-soft-coral: #fff0ec;
    --account-radius: 6px;
    --account-header: 72px;
}

* { box-sizing: border-box; }
html { color-scheme: light; }
body { margin: 0; color: var(--account-ink); background: var(--account-paper); font-family: Manrope, Arial, sans-serif; font-size: 16px; line-height: 1.5; letter-spacing: 0; -webkit-font-smoothing: antialiased; }
button, input, select { font: inherit; letter-spacing: 0; }
a { color: inherit; }

.account-skip-link { position: fixed; z-index: 100; top: 8px; left: 8px; padding: 10px 14px; background: var(--account-ink); color: #fff; transform: translateY(-160%); }
.account-skip-link:focus { transform: translateY(0); }
.account-wordmark { color: var(--account-ink); font-size: 20px; font-weight: 800; line-height: 1; text-decoration: none; }
.account-wordmark span { color: var(--account-coral); }
.account-kicker { margin: 0 0 10px; color: var(--account-green); font-family: "IBM Plex Mono", monospace; font-size: 12px; font-weight: 500; line-height: 1.3; text-transform: uppercase; }

/* Customer authentication */
.customer-auth-body { min-height: 100vh; background: var(--account-canvas); }
.customer-auth-header { height: var(--account-header); display: flex; align-items: center; justify-content: space-between; padding: 0 40px; border-bottom: 1px solid var(--account-line); }
.customer-auth-back { color: var(--account-muted); font-size: 14px; font-weight: 600; text-decoration: none; }
.customer-auth-back:hover { color: var(--account-ink); }
.customer-auth-main { width: min(1240px, calc(100% - 80px)); min-height: calc(100vh - 136px); margin: 0 auto; display: grid; grid-template-columns: minmax(320px, 1fr) minmax(460px, 560px); gap: 96px; align-items: center; padding: 64px 0; }
.customer-auth-intro { align-self: start; position: sticky; top: 120px; padding-top: 48px; }
.customer-auth-intro h1 { max-width: 760px; margin: 0; font-size: 72px; line-height: 0.98; font-weight: 800; letter-spacing: 0; }
.customer-auth-intro > p:last-child { max-width: 520px; margin: 28px 0 0; color: var(--account-muted); font-size: 18px; line-height: 1.65; }
.customer-auth-panel { width: 100%; padding: 48px; background: var(--account-paper); border: 1px solid var(--account-line); border-radius: var(--account-radius); }
.customer-auth-footer { min-height: 64px; padding: 20px 40px; display: flex; align-items: center; justify-content: space-between; color: var(--account-muted); border-top: 1px solid var(--account-line); font-size: 13px; }
.customer-auth-footer nav { display: flex; gap: 20px; }
.customer-auth-footer a { text-decoration: none; }
.auth-form-heading { margin-bottom: 30px; }
.auth-form-heading h2 { margin: 0; font-size: 32px; line-height: 1.15; }
.auth-form-heading > p:last-child { margin: 12px 0 0; color: var(--account-muted); }
.auth-switch { margin: 28px 0 0; color: var(--account-muted); text-align: center; font-size: 14px; }
.auth-switch a, .account-form-row a { color: var(--account-green); font-weight: 700; }

/* Shared forms and feedback */
.account-form { display: grid; gap: 18px; }
.account-field-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.account-field-grid.is-three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.account-field { display: grid; gap: 7px; color: var(--account-ink); font-size: 13px; font-weight: 700; }
.account-field span { display: flex; align-items: baseline; justify-content: space-between; }
.account-field small { color: var(--account-muted); font-size: 11px; font-weight: 500; }
.account-field > small { margin-top: -1px; line-height: 1.45; }
.account-field input, .account-field select { width: 100%; min-height: 48px; padding: 11px 13px; color: var(--account-ink); background: var(--account-paper); border: 1px solid #c9c9c2; border-radius: 4px; outline: none; }
.account-field input::placeholder { color: #92928b; }
.account-field input:focus, .account-field select:focus { border-color: var(--account-green); box-shadow: 0 0 0 3px rgba(21, 91, 69, .12); }
.account-checkbox { display: flex; gap: 10px; align-items: flex-start; color: var(--account-muted); font-size: 13px; font-weight: 500; }
.account-checkbox input { width: 17px; height: 17px; margin: 2px 0 0; accent-color: var(--account-green); flex: 0 0 auto; }
.account-checkbox a { color: var(--account-ink); }
.account-form-row { display: flex; align-items: center; justify-content: space-between; gap: 16px; font-size: 13px; }
.account-primary-button, .account-secondary-button { min-height: 50px; padding: 0 22px; display: inline-flex; align-items: center; justify-content: center; border: 1px solid transparent; border-radius: 4px; cursor: pointer; font-weight: 700; text-decoration: none; transition: background .2s ease, border-color .2s ease, color .2s ease, transform .2s ease; }
.account-primary-button { color: #fff; background: var(--account-green); }
.account-primary-button:hover { background: var(--account-green-dark); transform: translateY(-1px); }
.account-secondary-button { color: var(--account-ink); background: var(--account-paper); border-color: #b8b8b0; }
.account-secondary-button:hover { border-color: var(--account-ink); transform: translateY(-1px); }
.account-primary-button.is-compact, .account-secondary-button.is-compact { min-height: 42px; padding: 0 17px; font-size: 14px; }
.account-text-button { padding: 0; color: var(--account-green); background: transparent; border: 0; cursor: pointer; font-size: 13px; font-weight: 700; text-decoration: underline; text-underline-offset: 3px; }
.account-text-button.is-danger { color: #a33d2a; }
.account-alert { margin: 0 0 24px; padding: 13px 15px; border: 1px solid var(--account-line); border-radius: 4px; font-size: 14px; }
.account-alert.is-success { color: #174f3d; background: var(--account-soft-green); border-color: #bfd8cc; }
.account-alert.is-error { color: #862f1e; background: var(--account-soft-coral); border-color: #efc1b6; }
.account-alert.is-neutral { color: var(--account-muted); background: var(--account-canvas); }
.account-alert ul { margin: 0; padding-left: 20px; }

/* Authenticated account shell */
.customer-account-body { min-height: 100vh; background: var(--account-paper); }
.account-header { position: sticky; z-index: 20; top: 0; height: var(--account-header); background: rgba(255, 255, 255, .96); border-bottom: 1px solid var(--account-line); backdrop-filter: blur(10px); }
.account-header-inner { height: 100%; display: grid; grid-template-columns: 220px 1fr auto; align-items: center; padding: 0 32px; }
.account-header-label { color: var(--account-muted); font-size: 13px; font-weight: 600; }
.account-user-menu { display: flex; gap: 18px; align-items: center; justify-self: end; font-size: 13px; font-weight: 700; }
.account-shell { width: 100%; min-height: calc(100vh - var(--account-header)); display: grid; grid-template-columns: 252px minmax(0, 1fr); }
.account-sidebar { position: sticky; top: var(--account-header); height: calc(100vh - var(--account-header)); padding: 34px 24px; display: flex; flex-direction: column; justify-content: space-between; background: var(--account-canvas); border-right: 1px solid var(--account-line); }
.account-nav { display: grid; gap: 5px; }
.account-nav a { padding: 11px 12px; color: var(--account-muted); border-radius: 4px; font-size: 14px; font-weight: 600; text-decoration: none; }
.account-nav a:hover { color: var(--account-ink); background: #e9e9e4; }
.account-nav a.is-current { color: #fff; background: var(--account-ink); }
.account-back-link { padding: 11px 12px; color: var(--account-muted); font-size: 13px; font-weight: 600; text-decoration: none; }
.account-main { width: 100%; max-width: 1240px; padding: 56px clamp(28px, 5vw, 72px) 96px; }
.account-page-header { min-height: 126px; display: flex; justify-content: space-between; align-items: flex-start; gap: 32px; margin-bottom: 42px; padding-bottom: 34px; border-bottom: 1px solid var(--account-line); }
.account-page-header h1 { margin: 0; font-size: 40px; line-height: 1.1; letter-spacing: 0; }
.account-page-header p:last-child { max-width: 680px; margin: 12px 0 0; color: var(--account-muted); }
.account-stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); border-top: 1px solid var(--account-line); border-bottom: 1px solid var(--account-line); }
.account-stats a { min-height: 126px; padding: 22px; display: flex; flex-direction: column-reverse; justify-content: space-between; color: var(--account-muted); border-right: 1px solid var(--account-line); text-decoration: none; font-size: 13px; }
.account-stats a:last-child { border-right: 0; }
.account-stats a:hover { color: var(--account-ink); background: var(--account-canvas); }
.account-stats strong { color: var(--account-ink); font-size: 34px; line-height: 1; }
.account-section { margin-top: 64px; }
.account-notifications { border-top: 1px solid var(--account-line); }
.account-notification { display: flex; justify-content: space-between; gap: 24px; padding: 24px 0; border-bottom: 1px solid var(--account-line); }
.account-notification.is-unread { border-left: 3px solid var(--account-green); padding-left: 16px; }
.account-notification h2 { margin: 4px 0 8px; font-size: 18px; line-height: 1.3; }
.account-notification p { margin: 0 0 10px; color: var(--account-muted); }
.account-notification .account-notification-date { font-size: 12px; }
.account-notification a { color: var(--account-green); font-size: 13px; font-weight: 700; }
.account-notification form { flex: 0 0 auto; }
.account-section-heading { min-height: 54px; display: flex; align-items: flex-start; justify-content: space-between; gap: 24px; margin-bottom: 20px; }
.account-section-heading h2, .account-form-copy h2 { margin: 0; font-size: 24px; line-height: 1.2; }
.account-section-heading > a { color: var(--account-green); font-size: 13px; font-weight: 700; }
.account-empty { padding: 44px; background: var(--account-canvas); border: 1px solid var(--account-line); border-radius: var(--account-radius); text-align: center; }
.account-empty.is-large { padding: 90px 32px; }
.account-empty h2, .account-empty h3 { margin: 0 0 8px; font-size: 22px; }
.account-empty p { margin: 0 auto 18px; max-width: 580px; color: var(--account-muted); }
.account-empty a { color: var(--account-green); font-size: 14px; font-weight: 700; }
.account-table-wrap { width: 100%; overflow-x: auto; border-top: 1px solid var(--account-line); }
.account-table { width: 100%; min-width: 720px; border-collapse: collapse; font-size: 14px; }
.account-table th { padding: 14px 16px; color: var(--account-muted); border-bottom: 1px solid var(--account-line); text-align: left; font-size: 11px; font-weight: 700; text-transform: uppercase; }
.account-table td { padding: 18px 16px; border-bottom: 1px solid var(--account-line); vertical-align: middle; }
.account-table td small { display: block; margin-top: 3px; color: var(--account-muted); }
.account-table tbody tr:hover { background: #fafaf8; }
.account-status { display: inline-flex; min-height: 26px; padding: 4px 9px; align-items: center; color: #514f49; background: #efefeb; border-radius: 4px; font-size: 11px; font-weight: 700; text-transform: capitalize; white-space: nowrap; }
.account-status[data-status="delivered"], .account-status[data-status="approved"] { color: #15533e; background: var(--account-soft-green); }
.account-status[data-status="cancelled"] { color: #8c3524; background: var(--account-soft-coral); }
.account-status[data-status="in_production"], .account-status[data-status="in_review"] { color: #705313; background: #fff6db; }
.account-type-label, .account-default-label { display: inline-flex; font-size: 11px; font-weight: 700; text-transform: uppercase; }
.account-type-label { color: var(--account-green); }
.account-default-label { margin-left: 10px; color: var(--account-coral); }
.address-preview-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); border-top: 1px solid var(--account-line); }
.address-preview { padding: 24px 24px 4px 0; }
.address-preview + .address-preview { padding-left: 24px; border-left: 1px solid var(--account-line); }
.address-preview h3 { margin: 14px 0 8px; font-size: 17px; }
.address-preview p { margin: 0; color: var(--account-muted); font-size: 14px; line-height: 1.7; }
.account-form-section { display: grid; grid-template-columns: minmax(220px, .7fr) minmax(420px, 1.3fr); gap: 72px; padding: 40px 0 56px; border-bottom: 1px solid var(--account-line); }
.account-form-copy p:last-child { max-width: 340px; margin: 12px 0 0; color: var(--account-muted); font-size: 14px; }
.address-list { display: grid; gap: 16px; }
.address-card { border: 1px solid var(--account-line); border-radius: var(--account-radius); }
.address-card-summary { padding: 24px; display: flex; justify-content: space-between; gap: 24px; }
.address-card-labels { margin-bottom: 12px; }
.address-card h3 { margin: 0 0 8px; font-size: 18px; }
.address-card p { margin: 0; color: var(--account-muted); font-size: 14px; line-height: 1.65; }
.address-actions { display: flex; align-items: flex-start; gap: 16px; white-space: nowrap; }
.address-edit { border-top: 1px solid var(--account-line); }
.address-edit summary { padding: 15px 24px; color: var(--account-green); cursor: pointer; font-size: 13px; font-weight: 700; }
.address-edit[open] summary { border-bottom: 1px solid var(--account-line); }
.address-edit .account-form { padding: 24px; }
.design-list { border-top: 1px solid var(--account-line); }
.design-list-item { min-height: 118px; padding: 22px 4px; display: flex; align-items: center; justify-content: space-between; gap: 24px; border-bottom: 1px solid var(--account-line); }
.design-list-item h2 { margin: 8px 0 3px; font-size: 18px; }
.design-list-item p { margin: 0; color: var(--account-muted); font-size: 13px; }

@media (max-width: 1050px) {
    .customer-auth-main { grid-template-columns: minmax(260px, .8fr) minmax(420px, 1.2fr); gap: 48px; }
    .customer-auth-intro h1 { font-size: 54px; }
    .account-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .account-stats a:nth-child(2) { border-right: 0; }
    .account-stats a:nth-child(-n+2) { border-bottom: 1px solid var(--account-line); }
    .account-form-section { gap: 40px; }
}

@media (max-width: 780px) {
    :root { --account-header: 64px; }
    .customer-auth-header { padding: 0 20px; }
    .customer-auth-main { width: min(100% - 32px, 580px); min-height: auto; grid-template-columns: 1fr; gap: 36px; padding: 44px 0 56px; }
    .customer-auth-intro { position: static; padding-top: 0; }
    .customer-auth-intro h1 { font-size: 46px; }
    .customer-auth-intro > p:last-child { margin-top: 18px; font-size: 15px; }
    .customer-auth-panel { padding: 30px 22px; }
    .customer-auth-footer { padding: 18px 20px; }
    .account-header-inner { grid-template-columns: auto 1fr; padding: 0 18px; }
    .account-header-label { display: none; }
    .account-user-menu > span { display: none; }
    .account-shell { display: block; }
    .account-sidebar { position: sticky; z-index: 15; top: var(--account-header); width: 100%; height: auto; padding: 0; display: block; overflow-x: auto; border-right: 0; border-bottom: 1px solid var(--account-line); }
    .account-nav { width: max-content; min-width: 100%; display: flex; gap: 0; }
    .account-nav a { padding: 15px 16px; border-radius: 0; white-space: nowrap; }
    .account-nav a.is-current { color: var(--account-ink); background: transparent; box-shadow: inset 0 -3px var(--account-coral); }
    .account-back-link { display: none; }
    .account-main { padding: 38px 18px 72px; }
    .account-page-header { min-height: 0; margin-bottom: 32px; padding-bottom: 28px; }
    .account-page-header h1 { font-size: 32px; }
    .account-page-header .is-compact { flex: 0 0 auto; }
    .account-form-section { grid-template-columns: 1fr; gap: 28px; padding: 32px 0 44px; }
    .address-preview-grid { grid-template-columns: 1fr; }
    .address-preview + .address-preview { padding-left: 0; border-left: 0; border-top: 1px solid var(--account-line); }
}

@media (max-width: 560px) {
    .account-notification { flex-direction: column; gap: 10px; }
    .account-notification form { align-self: flex-start; }
    .customer-auth-intro h1 { font-size: 39px; }
    .customer-auth-footer { align-items: flex-start; flex-direction: column; gap: 8px; }
    .account-field-grid, .account-field-grid.is-three { grid-template-columns: 1fr; }
    .account-page-header { display: block; }
    .account-page-header .is-compact { margin-top: 22px; }
    .account-stats a { min-height: 106px; padding: 17px; }
    .account-stats strong { font-size: 29px; }
    .account-section { margin-top: 50px; }
    .account-empty, .account-empty.is-large { padding: 48px 20px; }
    .address-card-summary { display: block; }
    .address-actions { margin-top: 20px; }
    .design-list-item { align-items: flex-start; }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; }
}
