/* ============================================================
   PAINT FOR LIFE — CUSTOMER ACCOUNT
   Desktop + Tablet + Mobile
============================================================ */

.page-account {
    --account-brand: #2b565e;
    --account-brand-dark: #1f454c;
    --account-brand-soft: #edf5f4;
    --account-text: #111;
    --account-muted: #68716f;
    --account-border: #dfe8e6;
    --account-surface: #fff;
    --account-soft: #f7faf9;
    --account-danger: #b74747;
    --account-success: #317250;
    --account-warning: #9a6a17;
    --account-shadow: 0 16px 42px rgba(31, 69, 76, .06);
    background: #fff;
}

/* Compact hero */
.page-account .page-hero {
    min-height: 0 !important;
    height: auto !important;
    padding: 0 !important;
    border-bottom: 1px solid var(--account-border);
    background:
        radial-gradient(circle at 82% 18%, rgba(222, 239, 233, .75), transparent 22%),
        linear-gradient(90deg, #fff 0%, #fbfdfc 58%, #f4faf7 100%);
}

.page-account .page-hero .container {
    min-height: 0 !important;
    padding-top: 42px !important;
    padding-bottom: 38px !important;
}

.page-account .page-hero .eyebrow {
    margin: 0 0 8px;
    color: var(--account-brand);
    font-size: .7rem;
    font-weight: 700;
    letter-spacing: .11em;
    text-transform: uppercase;
}

.page-account .page-hero h1 {
    max-width: none;
    margin: 0 0 7px;
    color: var(--account-text);
    font-family: var(--font-heading, "Outfit", sans-serif);
    font-size: clamp(2.05rem, 3.15vw, 3rem);
    font-weight: 600;
    letter-spacing: -.038em;
    line-height: 1.02;
}

.page-account .page-hero p:not(.eyebrow) {
    max-width: 620px;
    margin: 0;
    color: var(--account-muted);
    font-size: .9rem;
    line-height: 1.5;
}

.account-hero__inner {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: space-between;
    overflow: hidden;
}

.account-hero__art {
    position: absolute;
    right: 4%;
    bottom: -26px;
    display: flex;
    gap: 14px;
    align-items: flex-end;
    opacity: .9;
    pointer-events: none;
}

.account-hero__art > span {
    display: block;
    width: 68px;
    height: 68px;
    border-radius: 50%;
    border: 8px solid rgba(255,255,255,.8);
    box-shadow: 0 10px 28px rgba(43,86,94,.08);
}
.account-hero__art > span:nth-child(1){background:#dff3ed; transform:translateY(8px)}
.account-hero__art > span:nth-child(2){background:#fce9dc; width:78px; height:78px}
.account-hero__art > span:nth-child(3){background:#ece7fa; transform:translateY(14px)}

.page-account .content-section {
    padding-top: 28px !important;
    padding-bottom: clamp(48px, 6vw, 72px);
}

.account-shell {
    display: grid;
    grid-template-columns: minmax(245px, 270px) minmax(0, 1fr);
    gap: 22px;
    align-items: start;
}

.account-sidebar,
.account-panel {
    border: 1px solid var(--account-border);
    border-radius: 18px;
    background: var(--account-surface);
    box-shadow: var(--account-shadow);
}

/* Sidebar */
.account-sidebar {
    position: sticky;
    top: 84px;
    overflow: hidden;
}

.account-sidebar__user {
    display: grid;
    grid-template-columns: 46px minmax(0, 1fr);
    gap: 12px;
    align-items: center;
    padding: 16px;
    border-bottom: 1px solid var(--account-border);
}

.account-sidebar__avatar {
    display: grid;
    width: 46px;
    height: 46px;
    place-items: center;
    border-radius: 50%;
    background: var(--account-brand-soft);
    color: var(--account-brand);
    font-size: .84rem;
    font-weight: 700;
}

.account-sidebar__identity { min-width: 0; }
.account-sidebar__identity strong,
.account-sidebar__identity small {
    display: block;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.account-sidebar__identity strong { color: var(--account-text); font-size: .9rem; font-weight: 600; }
.account-sidebar__identity small { margin-top: 3px; color: var(--account-muted); font-size: .69rem; }

.account-nav { display: grid; gap: 3px; padding: 9px; }
.account-nav__link {
    display: flex;
    min-height: 43px;
    align-items: center;
    gap: 10px;
    padding: 0 11px;
    border: 1px solid transparent;
    border-radius: 10px;
    color: #324240;
    font-size: .84rem;
    font-weight: 600;
    text-decoration: none;
    transition: background 160ms ease, color 160ms ease, border-color 160ms ease;
}
.account-nav__link:hover,
.account-nav__link:focus-visible { background:#f4f8f7; color:var(--account-brand); }
.account-nav__link.is-active { background:var(--account-brand-soft); color:var(--account-brand); }
.account-nav__link--logout { margin-top:8px; border-top:1px solid var(--account-border); border-radius:0; color:#596562; }
.account-nav__link--logout:hover { border-radius:10px; color:#a94646; }
.account-nav__icon { display:grid; width:19px; height:19px; flex:0 0 19px; place-items:center; }
.account-nav__icon svg,
.account-stat__icon svg,
.account-dashboard-card__icon svg,
.account-recent-order__mark svg,
.account-empty-state__icon svg,
.customer-order-view svg {
    width:100%; height:100%; fill:none; stroke:currentColor; stroke-width:1.7; stroke-linecap:round; stroke-linejoin:round;
}

/* Panel */
.account-panel { min-width:0; padding:clamp(22px, 3vw, 30px); }
.account-panel h2 { color:var(--account-brand); font-weight:600; }
.account-panel p { color:var(--account-muted); line-height:1.6; }

.account-section-heading {
    display:flex; align-items:flex-start; justify-content:space-between; gap:20px; margin-bottom:22px;
}
.account-section-heading h2 { margin:0 0 5px; font-size:1.25rem; }
.account-section-heading p { margin:0; font-size:.78rem; }
.account-order-count {
    display:inline-flex; min-height:30px; align-items:center; padding:5px 10px; border-radius:999px;
    background:var(--account-brand-soft); color:var(--account-brand); font-size:.68rem; font-weight:700; white-space:nowrap;
}
.account-text-link { color:var(--account-brand); font-size:.78rem; font-weight:600; text-decoration:none; }

/* Dashboard stats */
.account-card-grid { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:12px; margin-bottom:22px; }
.account-stat {
    display:grid; align-content:start; min-height:158px; padding:18px; border:1px solid var(--account-border); border-radius:16px;
    color:var(--account-text); text-decoration:none; transition:transform 160ms ease, box-shadow 160ms ease;
}
.account-stat:hover { transform:translateY(-2px); box-shadow:0 10px 26px rgba(31,69,76,.07); }
.account-stat--orders { background:linear-gradient(145deg,#f0faf7,#fbfdfc); }
.account-stat--wishlist { background:linear-gradient(145deg,#fff7f3,#fffdfb); }
.account-stat--addresses { background:linear-gradient(145deg,#f2f7ff,#fbfdff); }
.account-stat--profile { background:linear-gradient(145deg,#f8f3ff,#fefcff); }
.account-stat__icon {
    display:grid; width:38px; height:38px; place-items:center; margin-bottom:13px; border-radius:50%; color:var(--account-brand); background:rgba(255,255,255,.75);
}
.account-stat__icon svg { width:20px; height:20px; }
.account-stat__label { color:#65716e; font-size:.72rem; font-weight:600; }
.account-stat strong { margin-top:5px; color:#111; font-size:1.45rem; line-height:1.1; }
.account-stat__profile-value { font-size:1rem !important; line-height:1.25 !important; }
.account-stat small { margin-top:7px; color:#72807c; font-size:.68rem; }

.account-dashboard-card {
    position:relative; display:grid; grid-template-columns:42px minmax(0,1fr) auto; gap:14px; align-items:start;
    overflow:hidden; margin-bottom:22px; padding:22px; border:1px solid var(--account-border); border-radius:16px;
    background:linear-gradient(135deg,#fff 0%,#fbfdfc 60%,#f3faf7 100%);
}
.account-dashboard-card__icon { display:grid; width:42px; height:42px; place-items:center; border-radius:50%; background:var(--account-brand-soft); color:var(--account-brand); }
.account-dashboard-card__icon svg { width:21px; height:21px; }
.account-dashboard-card h2 { margin:2px 0 8px; font-size:1.1rem; }
.account-dashboard-card p { margin:0 0 14px; font-size:.8rem; }
.account-address-art { align-self:end; color:#d7e8e2; font-size:4rem; line-height:1; }

.account-recent-orders { padding-top:4px; }
.account-recent-orders__empty { padding:22px; border:1px dashed #ccd9d6; border-radius:14px; text-align:center; }
.account-recent-orders__empty p { margin:0 0 14px; }
.account-recent-order-list { display:grid; gap:9px; }
.account-recent-order {
    display:grid; grid-template-columns:40px minmax(0,1fr) auto auto; gap:12px; align-items:center;
    padding:12px 14px; border:1px solid var(--account-border); border-radius:13px; color:inherit; text-decoration:none;
}
.account-recent-order:hover { border-color:#c4d7d3; background:#fbfdfc; }
.account-recent-order__mark { display:grid; width:38px; height:38px; place-items:center; border-radius:10px; background:var(--account-brand-soft); color:var(--account-brand); }
.account-recent-order__mark svg { width:19px; height:19px; }
.account-recent-order__info { display:grid; gap:2px; min-width:0; }
.account-recent-order__info strong { color:#1b2422; font-size:.82rem; }
.account-recent-order__info small { color:#7b8784; font-size:.68rem; }
.account-recent-order__total { color:var(--account-brand); font-size:.82rem; }

/* Alerts */
.page-account .form-alert { margin-bottom:12px; padding:11px 13px; border:1px solid #efd2cf; border-radius:10px; background:#fff4f3; color:#99413e; font-size:.78rem; line-height:1.5; }
.page-account .form-alert--success { border-color:#cce5d7; background:#eff8f3; color:var(--account-success); }

/* Forms */
.page-account .contact-form { width:100%; }
.account-form-heading { margin-bottom:18px; }
.account-form-heading h2 { margin:0 0 5px; font-size:1.18rem; }
.account-form-heading p { margin:0; font-size:.78rem; }
.page-account .form-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:15px; }
.page-account .form-grid__full { grid-column:1/-1; }
.page-account .contact-form label { display:grid; gap:7px; }
.page-account .contact-form label > span { color:#46534f; font-size:.74rem; font-weight:600; }
.page-account .contact-form input,
.page-account .contact-form select,
.page-account .contact-form textarea {
    width:100%; min-height:46px; box-sizing:border-box; padding:10px 12px; border:1px solid #dce5e3; border-radius:10px;
    background:#fff; color:#202725; font-family:inherit; font-size:.8rem; outline:none;
}
.page-account .contact-form input:focus,
.page-account .contact-form select:focus,
.page-account .contact-form textarea:focus { border-color:var(--account-brand); box-shadow:0 0 0 3px rgba(43,86,94,.07); }
.page-account .check-row { display:flex !important; min-height:30px; flex-direction:row; align-items:center; gap:9px !important; }
.page-account .check-row input[type="checkbox"] { width:17px; height:17px; min-height:17px; flex:0 0 17px; padding:0; accent-color:var(--account-brand); }
.page-account .button { min-height:43px; border-radius:9px; font-size:.78rem; font-weight:600; }
.page-account .button--primary { border-color:var(--account-brand); background:var(--account-brand); color:#fff; }
.page-account .button--secondary { border-color:#ccd9d6; background:#fff; color:var(--account-brand); }
.page-account-profile .contact-form,
.page-account-change-password .contact-form { max-width:760px; }
.page-account-profile .contact-form > .button,
.page-account-change-password .contact-form > .button,
.address-form > .button { margin-top:18px; }
.account-password-form { display:grid; gap:15px; }
.account-password-form > label { max-width:600px; }

/* Addresses */
.address-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:14px; margin-bottom:24px; }
.address-card { display:grid; align-content:start; gap:11px; padding:18px; border:1px solid var(--account-border); border-radius:14px; background:#fff; }
.address-card__heading { display:flex; justify-content:space-between; gap:12px; align-items:center; }
.address-card__heading h2 { margin:0; font-size:1rem; }
.address-card__pin { color:#a9c1bc; font-size:1.2rem; }
.address-card p { margin:0; color:#596562; font-size:.78rem; line-height:1.7; }
.address-card__badges { display:flex; flex-wrap:wrap; gap:6px; }
.address-card__badges strong { display:inline-flex; padding:4px 8px; border-radius:999px; background:var(--account-brand-soft); color:var(--account-brand); font-size:.64rem; }
.address-card__actions { display:flex; gap:8px; flex-wrap:wrap; }
.address-card__actions form { margin:0; }
.address-card__actions form button { color:var(--account-danger); }
.address-form { margin-top:24px; padding-top:24px; border-top:1px solid var(--account-border); }
.account-inline-empty { margin-bottom:20px; padding:14px; border-radius:12px; background:#f8fbfa; }
.account-inline-empty p { margin:0; font-size:.78rem; }

/* Wishlist */
.wishlist-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:14px; }
.wishlist-item { display:grid; grid-template-columns:108px minmax(0,1fr); gap:14px; align-items:center; padding:13px; border:1px solid var(--account-border); border-radius:13px; background:#fff; }
.wishlist-item__image { display:block; width:108px; height:108px; border-radius:10px; overflow:hidden; background:#f4f7f6; }
.wishlist-item__image img { display:block; width:100%; height:100%; object-fit:cover; }
.wishlist-item h2 { margin:0 0 7px; font-size:.92rem; }
.wishlist-item h2 a { color:var(--account-text); text-decoration:none; }
.wishlist-item p { margin:0 0 11px; color:var(--account-brand); font-size:.82rem; font-weight:600; }

/* Orders */
.customer-order-list { display:grid; gap:12px; }
.customer-order-card { overflow:hidden; border:1px solid var(--account-border); border-radius:14px; background:#fff; }
.customer-order-card__main { display:flex; justify-content:space-between; gap:18px; align-items:flex-start; padding:17px 18px 14px; }
.customer-order-card__identity > span { display:block; margin-bottom:3px; color:#8a9491; font-size:.62rem; font-weight:600; text-transform:uppercase; }
.customer-order-card__identity h3 { margin:0 0 4px; color:#171b1a; font-size:1rem; font-weight:600; }
.customer-order-card__identity small { color:#798481; font-size:.68rem; }
.customer-status-badge { display:inline-flex; min-height:28px; align-items:center; padding:4px 10px; border-radius:999px; background:#f2f4f3; color:#56615e; font-size:.64rem; font-weight:700; }
.customer-status-badge--pending-payment,.customer-status-badge--pending { background:#fff4db; color:#8a651b; }
.customer-status-badge--processing { background:#edf5f4; color:#2b565e; }
.customer-status-badge--completed { background:#eaf6ee; color:#32734f; }
.customer-status-badge--cancelled,.customer-status-badge--refunded { background:#f9ecec; color:#a84646; }
.customer-order-card__meta { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); border-top:1px solid #edf1f0; border-bottom:1px solid #edf1f0; }
.customer-order-card__meta > div { display:grid; gap:4px; padding:13px 18px; border-right:1px solid #edf1f0; }
.customer-order-card__meta > div:last-child { border-right:0; }
.customer-order-card__meta span { color:#89928f; font-size:.62rem; }
.customer-order-card__meta strong { color:#3c4744; font-size:.76rem; }
.customer-order-total { color:var(--account-brand)!important; font-size:.86rem!important; }
.customer-payment-status--paid,.customer-payment-status--completed { color:#32734f!important; }
.customer-payment-status--pending { color:#8a651b!important; }
.customer-payment-status--failed,.customer-payment-status--cancelled { color:#a84646!important; }
.customer-order-card__footer { display:flex; justify-content:flex-end; padding:10px 14px; }
.customer-order-view { display:inline-flex; min-height:38px; align-items:center; gap:7px; padding:0 11px; border-radius:8px; color:var(--account-brand); font-size:.72rem; font-weight:600; text-decoration:none; }
.customer-order-view:hover { background:var(--account-brand-soft); }
.customer-order-view svg { width:15px; height:15px; }

/* Order details */
.account-order-detail-heading { display:flex; align-items:flex-start; justify-content:space-between; gap:18px; margin-bottom:20px; }
.account-order-detail-heading h2 { margin:7px 0 0; color:var(--account-text); font-size:1.5rem; }
.account-back-link { color:var(--account-brand); font-size:.72rem; font-weight:600; text-decoration:none; }
.account-order-summary-cards article { min-height:86px; padding:16px; border:1px solid var(--account-border); border-radius:13px; }
.account-order-summary-cards h2 { margin:0 0 7px; color:#6b7773; font-size:.7rem; }
.account-order-summary-cards strong { color:var(--account-brand); font-size:.9rem; }
.account-detail-section > h2 { margin:0 0 11px; font-size:1rem; }
.order-mini-list { overflow:hidden; margin:0 0 22px; border:1px solid var(--account-border); border-radius:13px; }
.order-mini-list p { display:flex; justify-content:space-between; gap:20px; margin:0; padding:13px 15px; border-bottom:1px solid #edf1f0; font-size:.78rem; }
.order-mini-list p:last-child { border-bottom:0; }
.account-order-detail-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:16px; }
.page-account-order-details .checkout-summary,
.account-shipping-card { padding:17px; border:1px solid var(--account-border); border-radius:13px; background:var(--account-soft); }
.page-account-order-details .checkout-summary p { display:flex; justify-content:space-between; gap:20px; margin:0; padding:8px 0; font-size:.78rem; }
.page-account-order-details .checkout-summary p:last-child { margin-top:5px; padding-top:12px; border-top:1px solid var(--account-border); color:var(--account-text); font-size:.9rem; }
.account-shipping-card p { margin:0; font-size:.8rem; }

/* Empty state */
.account-empty-state { display:grid; justify-items:center; padding:46px 20px; text-align:center; }
.account-empty-state__icon { display:grid; width:54px; height:54px; place-items:center; margin-bottom:15px; border-radius:50%; background:var(--account-brand-soft); color:var(--account-brand); }
.account-empty-state__icon svg { width:25px; height:25px; }
.account-empty-state h2 { margin:0 0 6px; font-size:1.15rem; }
.account-empty-state p { max-width:380px; margin:0 0 18px; font-size:.78rem; }

/* Tablet */
@media (max-width: 1100px) {
    .account-card-grid { grid-template-columns:repeat(2,minmax(0,1fr)); }
    .wishlist-grid { grid-template-columns:1fr; }
}

@media (max-width: 900px) {
    .account-shell { grid-template-columns:minmax(210px,230px) minmax(0,1fr); gap:16px; }
    .account-panel { padding:20px; }
}

/* Mobile account layout */
@media (max-width: 820px) {
    .page-account .page-hero .container { padding-top:26px!important; padding-bottom:24px!important; }
    .page-account .page-hero h1 { font-size:clamp(1.9rem,7vw,2.35rem); }
    .page-account .content-section { padding-top:16px!important; }
    .account-hero__art { display:none; }

    .account-shell { grid-template-columns:1fr; gap:14px; }
    .account-sidebar { position:static; border-radius:14px; }
    .account-sidebar__user { grid-template-columns:42px minmax(0,1fr); padding:13px 14px; }
    .account-sidebar__avatar { width:42px; height:42px; }

    .account-nav {
        display:grid;
        grid-template-columns:repeat(2,minmax(0,1fr));
        gap:8px;
        padding:10px;
        overflow:visible;
    }
    .account-nav__link {
        min-width:0;
        min-height:46px;
        justify-content:flex-start;
        padding:0 12px;
        border:1px solid var(--account-border);
        border-radius:10px;
        background:#fff;
        font-size:.76rem;
    }
    .account-nav__link.is-active { border-color:#c5d9d5; background:var(--account-brand-soft); }
    .account-nav__link--logout { margin-top:0; border-top:1px solid var(--account-border); border-radius:10px; }

    .account-card-grid--dashboard { grid-template-columns:repeat(2,minmax(0,1fr)); }
    .account-stat { min-height:136px; padding:15px; }
    .account-stat--addresses { grid-column:1/-1; min-height:112px; }
    .account-stat--profile { grid-column:1/-1; min-height:112px; }
    .account-dashboard-card { grid-template-columns:38px minmax(0,1fr); padding:18px; }
    .account-address-art { display:none; }
    .account-recent-order { grid-template-columns:36px minmax(0,1fr) auto; }
    .account-recent-order .customer-status-badge { grid-column:2/-1; justify-self:start; }
    .address-grid { grid-template-columns:1fr; }
    .account-order-detail-grid { grid-template-columns:1fr; }
}

@media (max-width: 760px) {
    .page-account .page-hero .container { padding-top:22px!important; padding-bottom:20px!important; }
    .page-account .page-hero .eyebrow { margin-bottom:5px; font-size:.64rem; }
    .page-account .page-hero h1 { margin-bottom:6px; font-size:1.9rem; }
    .page-account .page-hero p:not(.eyebrow) { font-size:.8rem; }
    .account-panel { padding:17px 13px; border-radius:14px; }
    .page-account .form-grid { grid-template-columns:1fr; }
    .page-account .form-grid__full { grid-column:auto; }
    .wishlist-grid { grid-template-columns:1fr; }
    .customer-order-card__meta { grid-template-columns:1fr; }
    .customer-order-card__meta > div { display:flex; justify-content:space-between; gap:15px; align-items:center; padding:10px 14px; border-right:0; border-bottom:1px solid #edf1f0; }
    .customer-order-card__meta > div:last-child { border-bottom:0; }
    .customer-order-view { width:100%; justify-content:center; }
}

@media (max-width: 520px) {
    .page-account .page-hero .container { padding-top:20px!important; padding-bottom:18px!important; }
    .page-account .page-hero h1 { font-size:1.72rem; }
    .page-account .content-section { padding-top:12px!important; }
    .account-sidebar__user { grid-template-columns:40px minmax(0,1fr); gap:10px; padding:12px; }
    .account-sidebar__avatar { width:40px; height:40px; font-size:.76rem; }
    .account-nav { gap:7px; padding:9px; }
    .account-nav__link { min-height:44px; padding:0 10px; font-size:.72rem; }
    .account-nav__icon { width:17px; height:17px; flex-basis:17px; }

    .account-card-grid--dashboard { gap:10px; margin-bottom:14px; }
    .account-stat { min-height:126px; padding:14px; }
    .account-stat__icon { width:34px; height:34px; margin-bottom:10px; }
    .account-stat strong { font-size:1.25rem; }
    .account-stat small { font-size:.64rem; }
    .account-stat--addresses,
    .account-stat--profile { min-height:102px; }

    .account-dashboard-card { margin-bottom:16px; padding:15px; }
    .account-dashboard-card__icon { width:36px; height:36px; }
    .account-dashboard-card h2 { font-size:1rem; }
    .account-dashboard-card .button { width:100%; justify-content:center; }

    .account-section-heading { align-items:center; margin-bottom:16px; }
    .account-section-heading h2 { font-size:1.08rem; }
    .account-section-heading p { font-size:.72rem; }

    .wishlist-item { grid-template-columns:82px minmax(0,1fr); gap:11px; padding:10px; }
    .wishlist-item__image { width:82px; height:82px; }
    .wishlist-item h2 { font-size:.82rem; }
    .wishlist-item p { font-size:.74rem; }
    .wishlist-item .button { width:100%; }

    .account-order-detail-heading { display:grid; gap:10px; }
    .account-order-detail-heading .customer-status-badge { justify-self:start; }
    .account-order-summary-cards { grid-template-columns:repeat(2,minmax(0,1fr)); }
    .account-order-summary-cards article { min-height:76px; padding:13px; }

    .page-account .contact-form input,
    .page-account .contact-form select,
    .page-account .contact-form textarea { font-size:16px; }
}

@media (max-width: 380px) {
    .account-nav { grid-template-columns:1fr; }
    .account-card-grid--dashboard { grid-template-columns:1fr; }
    .account-stat--addresses,
    .account-stat--profile { grid-column:auto; }
}
