/* Customer account (/account/*), on top of the help-page styles in pages.css. Prefix ac-. */

.ac-wrap { max-width: 1000px; padding-block: clamp(20px, 3vw, 32px) clamp(56px, 7vw, 96px); }
.ac-chips { margin-top: 0; }
.ac-wrap > .hp-notice { margin-top: 1.4rem; }

.ac-section { border-top: 2px solid var(--navy); margin-top: clamp(32px, 5vw, 56px); padding-top: 1.4rem; scroll-margin-top: 96px; }
.ac-section__head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; }
.ac-h2 { margin: 0; font-size: clamp(1.7rem, 3vw, 2.4rem); line-height: 1; letter-spacing: -.02em; color: var(--navy); }
.ac-h3 { margin: 2.2rem 0 0; font-size: 1.3rem; color: var(--navy); }
.ac-note, .ac-empty { max-width: 62ch; margin: .8rem 0 0; color: var(--muted); }
.ac-note a, .ac-empty a, .ac-perks + p a, .hp-details a { color: var(--navy); text-decoration: underline; text-underline-offset: 2px; }
.ac-perks { margin: 0 0 1rem; padding-left: 1.1em; line-height: 1.6; }

.ac-btn-sm { height: 42px; padding: 0 18px; font-size: 14px; }
.ac-btn-danger { background: var(--white); color: #a50e26; border-color: #a50e26; }
.ac-btn-danger:hover { background: #fdf2f4; }

/* Text-style buttons (sign out, make default, delete) */
.ac-linkbtn { padding: 0; border: 0; background: none; font: inherit; font-size: 15px; font-weight: 600; color: var(--navy); text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.ac-linkbtn:hover { color: var(--blue-ink); }
.ac-linkbtn--danger { color: #a50e26; }
.ac-linkbtn--danger:hover { color: #7a0a1c; }
.ac-link { font-weight: 600; color: var(--navy); text-decoration: underline; text-underline-offset: 3px; }
.ac-link:hover { color: var(--blue-ink); }
.ac-signout { margin-top: 1rem; }

/* Orders */
.ac-orders { list-style: none; margin: 1rem 0 0; padding: 0; }
.ac-order { padding: 18px 0; border-bottom: 1px solid var(--line); }
.ac-order__head { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; }
.ac-order__name { margin: 0; font: 800 1.2rem/1.2 var(--display); color: var(--navy); }
.ac-order__meta { margin: .35rem 0 0; font-size: 14px; color: var(--muted); }
.ac-order__items { margin: .35rem 0 .6rem; font-size: 15px; color: var(--ink); overflow-wrap: anywhere; }
.ac-track { margin: .35rem 0 0; font-size: 14px; color: var(--ink); overflow-wrap: anywhere; }

.ac-pill { display: inline-block; padding: 3px 10px; border-radius: 99px; font-size: 12px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; line-height: 1.5; }
.ac-pill--ok { background: #e3f1e7; color: #1d5b2e; }
.ac-pill--info { background: #e6effa; color: #1f4f86; }
.ac-pill--muted { background: var(--plate); color: #4a596d; }

/* Addresses */
.ac-addrs { list-style: none; margin: 1rem 0 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 260px), 1fr)); gap: 16px; }
.ac-addr { display: flex; flex-direction: column; gap: 10px; padding: 18px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--white); }
.ac-addr.is-default { border-color: var(--navy); }
.ac-addr .ac-pill { align-self: flex-start; }
.ac-addr__lines { margin: 0; font-size: 15px; line-height: 1.55; overflow-wrap: anywhere; }
.ac-addr__lines b { color: var(--navy); }
.ac-addr__actions { margin-top: auto; display: flex; flex-wrap: wrap; align-items: center; gap: 8px 18px; }
.ac-addr__actions form { margin: 0; }
.ac-addr__actions .ac-link, .ac-addr__actions .ac-linkbtn { display: inline-block; min-height: 24px; font-size: 14px; }

/* Email preferences + delete */
.ac-prefs, .ac-delete { margin-top: 1rem; display: grid; gap: 14px; justify-items: start; }
.ac-prefs fieldset { margin: 0; padding: 0; border: 0; display: grid; gap: 10px; }
.ac-prefs legend { margin-bottom: 8px; padding: 0; font-weight: 600; color: var(--navy); }
.ac-radio, .ac-check { display: flex; align-items: flex-start; gap: 10px; font-size: 15px; font-weight: 400; color: var(--ink); cursor: pointer; }
.hp-field .ac-check { font-weight: 400; color: var(--ink); }
.ac-radio input, .ac-check input, .hp-field .ac-check input { flex: none; display: inline-block; width: 20px; height: 20px; margin: 1px 0 0; padding: 0; border: 0; accent-color: var(--navy); }
.ac-radio b { color: var(--navy); }

@media (max-width: 600px) {
  .ac-section__head .btn { width: 100%; }
  .ac-prefs .btn, .ac-delete .btn { width: 100%; }
}
.ac-section .hp-notice { margin-top: 1rem; }

/* ---- Account dashboard (/account: templates/account/index.php) ------------------------------ */

/* Welcome band: navy like the hero, stats, sign out, a customer photo tile (megamenu .mega-tile) */
.ac-hero { background: var(--band); color: var(--white); }
.ac-hero__grid { display: grid; grid-template-columns: minmax(0, 1fr) 240px; gap: clamp(24px, 5vw, 64px); align-items: end; padding-block: clamp(22px, 3vw, 34px) clamp(30px, 4vw, 44px); }
.ac-crumbs { font-size: 13px; color: rgba(255,255,255,.7); }
.ac-crumbs a { color: rgba(255,255,255,.85); text-decoration: underline; text-underline-offset: 3px; }
.ac-crumbs a:hover { color: var(--white); }
.ac-eyebrow { margin: clamp(1.2rem, 3vw, 2rem) 0 .5rem; font-family: var(--display); font-weight: 700; font-size: 12px; letter-spacing: .2em; text-transform: uppercase; color: var(--gold); }
.ac-hero__title { font-size: clamp(2.6rem, 6vw, 4.4rem); line-height: .95; letter-spacing: -.025em; overflow-wrap: anywhere; }
.ac-hero__lede { margin: .8rem 0 0; color: rgba(255,255,255,.82); overflow-wrap: anywhere; }
.ac-hero__lede b { color: var(--white); font-weight: 600; }
.ac-stats { display: flex; flex-wrap: wrap; gap: 10px; margin: 1.6rem 0 0; }
.ac-stats div { min-width: 112px; padding: 12px 16px 10px; border: 1px solid rgba(255,255,255,.16); border-radius: 12px; background: rgba(255,255,255,.06); }
.ac-stats dt { font-family: var(--display); font-weight: 700; font-size: 11px; letter-spacing: .16em; text-transform: uppercase; color: var(--blue-soft); }
.ac-stats dd { margin: 2px 0 0; font: 800 26px/1.15 var(--display); color: var(--white); }
.ac-stats dd a { color: inherit; background: linear-gradient(var(--gold), var(--gold)) 0 100% / 0 3px no-repeat; transition: background-size .25s cubic-bezier(.2,.7,.2,1); }
.ac-stats dd a:hover, .ac-stats dd a:focus-visible { background-size: 100% 3px; }
.ac-hero__actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 22px; margin-top: 1.6rem; }
.ac-hero__actions form { margin: 0; }
.ac-signout { min-height: 44px; padding: 0; border: 0; background: none; font: 600 15px var(--body); color: var(--white); text-decoration: underline; text-underline-offset: 4px; cursor: pointer; }
.ac-signout:hover { color: var(--gold); }
.ac-hero__photo.mega-tile { width: 100%; box-shadow: 0 18px 40px rgba(2,13,28,.35); }
.ac-hero__photo img { height: 100%; }

/* Section nav beside the content (chips on phones) */
.ac-dash { display: grid; grid-template-columns: 200px minmax(0, 1fr); gap: clamp(28px, 4vw, 56px); align-items: start; padding-block: clamp(28px, 4vw, 44px) clamp(56px, 7vw, 96px); }
.ac-nav { position: sticky; top: 96px; display: grid; gap: 2px; }
.ac-nav a { display: flex; justify-content: space-between; align-items: center; gap: 8px; min-height: 44px; padding: 0 14px; border-left: 3px solid var(--line); font-weight: 600; font-size: 15px; color: var(--navy); transition: border-color .15s, background .15s; }
.ac-nav a:hover, .ac-nav a:focus-visible { border-left-color: var(--gold); background: var(--mist); }
.ac-nav small, .ac-more summary small { min-width: 24px; padding: 1px 7px; border-radius: 99px; background: var(--plate); font-size: 12px; font-weight: 700; text-align: center; color: var(--muted); }
.ac-main { min-width: 0; }
.ac-main > .hp-notice { margin: 0 0 1.4rem; }
.ac-main .ac-section { margin-top: clamp(36px, 5vw, 56px); padding-top: 0; border-top: 0; }
.ac-main .ac-section:first-of-type { margin-top: 0; }
.ac-main .ac-h2 { display: flex; align-items: center; gap: 14px; font-size: clamp(1.6rem, 2.6vw, 2.1rem); }
.ac-main .ac-section__head { margin-bottom: 1rem; }
.ac-main .ac-section__head .ac-link { font-size: 14px; }

/* Orders: photo strip + status, the whole card is the link */
.ac-main .ac-orders { display: grid; gap: 12px; margin: 0; }
.ac-main .ac-order { padding: 0; border: 0; }
.ac-order__card { display: block; border: 1px solid var(--line); border-radius: 16px; background: var(--white); transition: border-color .15s, box-shadow .2s; }
a.ac-order__card, .ac-order__card > summary { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 18px; align-items: center; padding: 14px 18px 14px 14px; color: inherit; }
.ac-order__card > summary { list-style: none; cursor: pointer; border-radius: 16px; }
.ac-order__card > summary::-webkit-details-marker { display: none; }
a.ac-order__card:hover, a.ac-order__card:focus-visible, .ac-order__card > summary:hover, .ac-order__card[open] { border-color: var(--navy); box-shadow: 0 10px 28px rgba(4,30,66,.08); }
.ac-order__card > summary:focus-visible { outline-offset: -2px; }
.ac-order__thumbs { display: flex; }
.ac-thumb { flex: none; display: grid; place-items: center; width: 64px; height: 80px; border-radius: 10px; overflow: hidden; background: var(--plate); box-shadow: 0 0 0 3px var(--white); font: 800 22px var(--display); color: var(--navy); }
.ac-order__thumbs .ac-thumb + .ac-thumb { margin-left: -22px; }
.ac-thumb img { width: 100%; height: 100%; object-fit: cover; }
.ac-thumb--more { background: var(--navy); color: var(--white); font-size: 16px; }
.ac-order__body { display: grid; gap: 4px; min-width: 0; }
.ac-order__head { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 12px; }
.ac-order__name { font: 800 1.2rem/1.2 var(--display); color: var(--navy); }
.ac-order__meta { font-size: 14px; color: var(--muted); }
.ac-order__go { justify-self: start; display: inline-flex; align-items: center; gap: 6px; margin-top: 2px; font-weight: 600; font-size: 14px; color: var(--navy); background: linear-gradient(var(--gold), var(--gold)) 0 100% / 0 2px no-repeat; transition: background-size .25s cubic-bezier(.2,.7,.2,1); }
.ac-order__go::after { content: "→"; color: var(--gold-line); transition: transform .25s cubic-bezier(.2,.7,.2,1); }
a.ac-order__card:hover .ac-order__go, .ac-order__card > summary:hover .ac-order__go { background-size: 100% 2px; }
a.ac-order__card:hover .ac-order__go::after { transform: translateX(3px); }
.ac-order__card--legacy .ac-order__go::after { content: "+"; font-size: 18px; line-height: 1; }
.ac-order__card--legacy[open] .ac-order__go::after { content: "−"; }
.ac-order__close, .ac-order__card[open] .ac-order__open { display: none; }
.ac-order__card[open] .ac-order__close { display: inline; }
.ac-order__extra { display: inline-block; margin: 8px 0 0 18px; font-size: 14px; }

/* Ordered → Packed → Shipped */
.ac-steps { display: grid; grid-template-columns: repeat(3, minmax(0, 92px)); margin: 6px 0 2px; border-top: 3px solid var(--line); }
.ac-steps i { position: relative; padding-top: 5px; font-style: normal; font-size: 12px; font-weight: 600; color: var(--muted); }
.ac-steps i.is-done { color: var(--navy); }
.ac-steps i.is-done::before { content: ""; position: absolute; top: -3px; left: 0; right: 0; height: 3px; background: var(--gold); }

/* An older order, opened */
.ac-order__detail { padding: 4px 18px 16px; border-top: 1px solid var(--line); }
.ac-lines { list-style: none; margin: 0; padding: 0; }
.ac-lines li { display: grid; grid-template-columns: 64px minmax(0, 1fr) auto; gap: 14px; align-items: center; padding: 10px 0; border-bottom: 1px solid var(--line); }
.ac-lines li > span:nth-child(2) { display: grid; gap: 2px; min-width: 0; overflow-wrap: anywhere; }
.ac-lines b { color: var(--navy); }
.ac-lines small { font-size: 13px; color: var(--muted); }
.ac-lines__amt { font: 700 16px var(--display); color: var(--navy); }
.ac-order__detail .ac-track { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 6px 14px; margin: 12px 0 0; padding: 12px 14px; border-radius: 10px; background: var(--mist); font-weight: 600; color: var(--navy); }
.ac-order__detail .ac-note { margin-top: 12px; font-size: 14px; }

.ac-more { margin-top: 14px; }
.ac-more > summary { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; padding: 0 18px; border: 1px solid var(--navy); border-radius: var(--radius); font-weight: 600; font-size: 15px; color: var(--navy); cursor: pointer; list-style: none; }
.ac-more > summary::-webkit-details-marker { display: none; }
.ac-more > summary:hover { background: var(--mist); }
.ac-more[open] > summary { margin-bottom: 12px; }

.ac-empty-card, .ac-credit { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 14px 24px; padding: 22px 24px; border-radius: 16px; background: var(--mist); }
.ac-empty-card p, .ac-credit p { margin: 0; }
.ac-credit { border-left: 4px solid var(--gold); }
.ac-credit p { flex: 1 1 260px; }
.ac-credit b { font: 800 1.4rem var(--display); color: var(--navy); }

/* Addresses */
.ac-main .ac-addrs { margin: 0; }
.ac-main .ac-addr { border-radius: 16px; padding: 20px; }
.ac-main .ac-addr.is-default { border: 2px solid var(--navy); padding: 19px; }
.ac-pill--gold { background: var(--gold); color: var(--navy); }

/* Email + delete side by side */
.ac-pair { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; margin-top: clamp(36px, 5vw, 56px); }
.ac-main .ac-pair .ac-card { margin: 0; padding: 22px 24px 24px; border: 1px solid var(--line); border-radius: 16px; background: var(--white); scroll-margin-top: 96px; }
.ac-main .ac-card .ac-h2 { font-size: 1.45rem; }
.ac-card .ac-note { font-size: 15px; }
.ac-card .ac-prefs, .ac-card .ac-delete { margin-top: 1rem; }

@media (max-width: 960px) {
  .ac-dash { grid-template-columns: minmax(0, 1fr); gap: 24px; }
  .ac-nav { position: static; display: flex; gap: 8px; overflow-x: auto; margin-inline: -16px; padding: 0 16px 4px; scrollbar-width: none; }
  .ac-nav::-webkit-scrollbar { display: none; }
  .ac-nav a { flex: none; min-height: 40px; border: 1px solid var(--line); border-radius: 99px; }
  .ac-nav a:hover, .ac-nav a:focus-visible { border-color: var(--navy); }
  .ac-pair { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 760px) {
  .ac-hero__grid { grid-template-columns: minmax(0, 1fr); }
  .ac-hero__photo { display: none; }
  .ac-stats { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); gap: 8px; margin-top: 1.2rem; }
  .ac-stats div { min-width: 0; padding: 10px 10px 8px; }
  .ac-stats dt { font-size: 10px; letter-spacing: .1em; }
  .ac-stats dd { font-size: 21px; }
  .ac-hero__actions { margin-top: 1.2rem; }
}
@media (max-width: 520px) {
  a.ac-order__card, .ac-order__card > summary { gap: 12px; padding: 12px; align-items: start; }
  .ac-order__name { font-size: 1.05rem; }
  .ac-order__thumbs .ac-thumb { width: 52px; height: 65px; }
  .ac-order__thumbs .ac-thumb + .ac-thumb { display: none; }
  .ac-order__thumbs .ac-thumb--more { display: none; }
  .ac-thumb { width: 56px; height: 70px; }
  .ac-order__detail { padding: 4px 14px 14px; }
  .ac-lines li { grid-template-columns: 56px minmax(0, 1fr); }
  .ac-lines__amt { grid-column: 2; }
  .ac-order__extra { margin-left: 14px; }
}
@media (prefers-reduced-motion: reduce) {
  .ac-order__go, .ac-order__go::after, .ac-stats dd a { transition: none; }
}
