/* ==========================================================================
   Giassaris — Account pages (auth + dashboard)
   ========================================================================== */

/* ---- Account header (centered logo) ---- */
.acc-header { height: 105px; display: flex; align-items: center; justify-content: center; }
.acc-header img { height: 50px; }

/* ==========================================================================
   Auth (login / register / forgot)
   ========================================================================== */
.auth { max-width: 1190px; margin: 0 auto; padding-block: 64px 96px; }
.auth--split { display: grid; grid-template-columns: 1fr 1px 1fr; gap: 64px; align-items: start; }
.auth__divider { align-self: stretch; background: var(--c-border); }
.auth__col { max-width: 434px; width: 100%; }
.auth__col--center { margin-inline: auto; }
.auth h1 { font-size: var(--fs-xl); font-weight: var(--fw-bold); }
.auth__sub { color: var(--c-text-muted); font-size: var(--fs-sm); margin: 14px 0 28px; line-height: 1.5; }
.auth__form { display: grid; gap: 16px; }
.auth__row { display: flex; align-items: center; justify-content: space-between; }
.auth__forgot { display: flex; align-items: center; justify-content: center; gap: 7px; margin-top: 16px; font-size: var(--fs-xs); font-weight: var(--fw-medium); color: var(--c-text-muted); }
.auth__forgot:hover { color: var(--c-accent); }
.auth .btn { height: 49px; }

@media (max-width: 860px) {
  .auth--split { grid-template-columns: 1fr; gap: 40px; }
  .auth__divider { height: 1px; width: 100%; }
}

/* ==========================================================================
   Account layout (logged-in: sidebar + content)
   ========================================================================== */
.acc-layout { display: grid; grid-template-columns: 283px 1fr; gap: 24px; align-items: start; padding-block: 32px 64px; max-width: 1400px; margin: 0 auto; }

.acc-sidebar { background: #fff; border: 1px solid var(--c-border); border-radius: var(--radius-lg); padding: 16px; padding-left: 0; position: sticky; top: 24px; box-shadow: 0 2px 12px rgba(0,0,0,.08); }
.acc-nav { display: grid; gap: 4px; }
.acc-nav a { display: flex; align-items: center; gap: 12px; padding: 12px 16px; border-radius: var(--radius-sm); font-size: var(--fs-sm); font-weight: var(--fw-medium); color: var(--c-grey-500); position: relative; transition: color var(--t-fast); }
.acc-nav a i { color: var(--c-ink); transition: color var(--t-fast); }
.acc-nav a svg { width: 20px; height: 20px; flex: none; }
.acc-nav a:hover { color: var(--c-accent); }
.acc-nav a:hover i { color: var(--c-accent); }
.acc-nav a.is-active { color: var(--c-accent); background: none; }
.acc-nav a.is-active i { color: var(--c-accent); }
.acc-nav a.is-active::before { content: ""; position: absolute; left: 0; top: 9px; bottom: 9px; width: 3px; border-radius: 3px; background: var(--c-accent); }
.acc-nav a.acc-nav__sep { margin-top: 10px; }
.acc-nav a.acc-nav__logout { color: var(--c-grey-500); margin-top: 10px; border-top: 1px solid var(--c-border); border-radius: 0; padding-top: 16px; }
.acc-nav a.acc-nav__logout:hover { color: var(--c-accent); }
.acc-nav a.acc-nav__logout:hover i { color: var(--c-accent); }

/* content card */
.acc-card { background: #fff; border: 1px solid var(--c-border); border-radius: var(--radius-lg); padding: 32px 36px; box-shadow: 0 2px 12px rgba(0,0,0,.08); }
.acc-content h1 { font-size: 28px; font-weight: var(--fw-bold); }
.acc-content__sub { color: var(--c-text-muted); font-size: var(--fs-sm); margin-top: 8px; }
.acc-content__head { margin-bottom: 28px; display: flex; align-items: center; justify-content: space-between; }

/* dashboard welcome */
.acc-welcome { padding-bottom: 22px; margin-bottom: 24px; border-bottom: 1px solid var(--c-border); }
.acc-welcome span { font-size: var(--fs-sm); color: var(--c-text-muted); }
.acc-welcome b { display: block; font-size: 24px; font-weight: var(--fw-bold); margin-top: 4px; }

/* dashboard box links */
.dash-boxes { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-bottom: 32px; }
.dash-box { background: var(--c-grey-100); border-radius: var(--radius); padding: 22px 24px; box-shadow: 0 2px 8px rgba(0,0,0,.08); }
.dash-box__icon { color: var(--c-accent); margin-bottom: 8px; }
.dash-box__icon svg { width: 26px; height: 26px; }
.dash-box__label { font-size: var(--fs-sm); color: var(--c-text-muted); }
.dash-box__num { font-size: 24px; font-weight: var(--fw-bold); margin-top: 2px; }

/* order box */
.section-title { font-size: var(--fs-sm); font-weight: var(--fw-bold); margin-bottom: 16px; }
.order-box { display: grid; grid-template-columns: 1fr 1fr auto; gap: 16px 24px; align-items: stretch; border: 1px solid var(--c-border); border-radius: var(--radius); padding: 18px 22px; margin-bottom: 6px; box-shadow: 0 2px 8px rgba(0,0,0,.06); }
.ob-cell { display: grid; gap: 14px; }
.ob-field__label { font-size: 11px; color: var(--c-grey-500); }
.ob-field__value { font-size: var(--fs-sm); font-weight: var(--fw-medium); margin-top: 2px; }
.order-box__right { display: flex; flex-direction: column; align-items: flex-end; justify-content: space-between; height: 100%; }
.order-box__link { font-size: var(--fs-xs); color: var(--c-text-muted); white-space: nowrap; }
.order-box__link:hover { color: var(--c-accent); }
.badge-status { font-size: 11px; font-weight: var(--fw-bold); padding: 6px 12px; border-radius: 5px; }
.badge-status--done { background: #0a9d4a; color: #fff; }
.badge-status--shipped { background: #1565d8; color: #fff; }
.badge-status--progress { background: #e08600; color: #fff; }
.badge-status--canceled { background: #d32f2f; color: #fff; }
@media (max-width: 640px) { .order-box { grid-template-columns: 1fr; } .dash-boxes { grid-template-columns: 1fr; } }
.acc-form { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; max-width: 880px; }
.acc-form .full { grid-column: 1 / -1; }
.acc-form__actions { grid-column: 1 / -1; }

@media (max-width: 1023px) {
  .acc-layout { grid-template-columns: 1fr; }
  /* menu (sidebar) on top, content below — natural DOM order, so no reorder.
     min-width:0 stops the grid item from inflating the track to its content's
     min-content (grid blowout) — keeps wide rows (product/data) within the screen. */
  .acc-content { min-width: 0; }
  .acc-sidebar { position: static; }
  .acc-form { grid-template-columns: 1fr; }
}

/* ---- Page head with icon + subtitle + back ---- */
.acc-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; padding-bottom: 24px; margin-bottom: 28px; border-bottom: 1px solid var(--c-border); }
.acc-head__title { display: flex; gap: 14px; }
.acc-head__icon { color: var(--c-text); margin-top: 2px; }
.acc-head__icon svg { width: 26px; height: 26px; }
.acc-head h1 { font-size: 24px; font-weight: var(--fw-bold); }
.acc-head__sub { color: var(--c-text-muted); font-size: var(--fs-sm); margin-top: 4px; }
.acc-back { display: inline-flex; align-items: center; gap: 8px; font-size: var(--fs-sm); color: var(--c-black); white-space: nowrap; }
.acc-back i { width: 20px; height: 20px; border: 1.5px solid var(--c-black); border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; font-size: 11px; color: var(--c-black); }
.acc-back:hover { color: var(--c-accent); }
.acc-back:hover i { border-color: var(--c-accent); color: var(--c-accent); }

/* Phones: the page head puts the title and a nowrap "back" link on one flex row.
   Its min-width overflows the card on narrow screens — stack them instead. */
@media (max-width: 560px) {
  .acc-head, .acc-content__head { flex-direction: column; align-items: flex-start; gap: 14px; }
  /* label + value pairs: let the value wrap under the label so an unbreakable
     label token (e.g. "Ονοματεπώνυμο:") can't pin the card wider than the screen */
  .data-line { flex-wrap: wrap; }
  /* form submit buttons go full-width; long labels wrap instead of overflowing */
  .acc-card form .btn { width: 100%; white-space: normal; }
  /* trim the card's side padding on phones (36px desktop is too inset here) */
  .acc-card { padding-inline: 16px; }
}

/* ---- Address box ---- */
.addr-list { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.addr-box { border: 1px solid var(--c-border); border-radius: var(--radius); padding: 22px; }
.addr-box__badge { display: inline-block; background: var(--c-black); color: #fff; font-size: 11px; font-weight: var(--fw-bold); padding: 6px 12px; border-radius: var(--radius-sm); margin-bottom: 14px; }
.addr-box__name { font-weight: var(--fw-bold); margin-bottom: 14px; }
.addr-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px 20px; }
.addr-grid .lbl { font-size: 11px; color: var(--c-grey-500); }
.addr-grid .val { font-size: var(--fs-sm); margin-top: 2px; }
.addr-box__actions { display: flex; justify-content: space-between; margin-top: 18px; padding-top: 16px; border-top: 1px solid var(--c-border); font-size: var(--fs-xs); }
.addr-box__actions a { color: var(--c-text-muted); display: inline-flex; align-items: center; gap: 6px; }
.addr-box__actions a:hover { color: var(--c-accent); }
@media (max-width: 768px) { .addr-list { grid-template-columns: 1fr; } }

/* ---- Order detail blocks ---- */
.acc-block { background: var(--c-grey-100); border: 1px solid var(--c-border); border-radius: var(--radius); padding: 20px 22px; margin-bottom: 4px; }
.acc-block__head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; }
.acc-block__title { font-size: var(--fs-sm); font-weight: var(--fw-bold); }
.data-line { display: flex; gap: 6px; font-size: var(--fs-sm); padding: 5px 0; }
.data-line b { font-weight: var(--fw-bold); }
.data-line span { color: var(--c-text-muted); }
.two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; }
.totals .data-line { gap: 6px; }
@media (max-width: 768px) { .two-col { grid-template-columns: 1fr; } }

/* ---- Account product row (order details) ---- */
.acc-prod { display: grid; grid-template-columns: 64px 1fr auto; gap: 16px; align-items: center; background: #fff; border: 1px solid var(--c-border); border-radius: var(--radius); padding: 14px; margin-bottom: 10px; }
.acc-prod__thumb { width: 64px; height: 64px; background: var(--c-grey-150); border-radius: var(--radius-sm); display: grid; place-items: center; overflow: hidden; }
.acc-prod__thumb img { width: 100%; height: 100%; object-fit: contain; padding: 6px; }
.acc-prod__title { font-size: var(--fs-sm); font-weight: var(--fw-bold); }
.acc-prod__opts { font-size: var(--fs-xs); color: var(--c-grey-500); margin-top: 4px; }
.acc-prod__right { text-align: right; }
.acc-prod__qty { font-size: var(--fs-xs); color: var(--c-grey-500); }
.acc-prod__price { font-weight: var(--fw-bold); color: var(--c-accent); }
.acc-prod__price del { display: block; color: var(--c-grey-500); font-weight: var(--fw-book); text-decoration: line-through; font-size: var(--fs-xs); }

/* ---- Points ---- */
.points-total { display: flex; justify-content: space-between; align-items: center; background: var(--c-grey-100); border-radius: var(--radius); padding: 18px 22px; margin-bottom: 24px; font-size: var(--fs-sm); }
.points-total b { background: var(--c-black); color: #fff; padding: 6px 16px; border-radius: var(--radius-sm); font-size: var(--fs-sm); }
.dtable { width: 100%; border-collapse: collapse; }
.dtable th { text-align: left; font-size: 14px; color: var(--c-black); font-weight: var(--fw-bold); padding: 0 0 14px; border-bottom: 1px solid var(--c-border); }
.dtable td { padding: 16px 0; font-size: var(--fs-sm); border-bottom: 1px solid var(--c-border); }

/* ---- Returns / form sections ---- */
.acc-sec-title { font-size: var(--fs-base); font-weight: var(--fw-bold); margin: 8px 0 16px; }
.acc-divider { border: none; border-top: 1px solid var(--c-border); margin: 28px 0; }
/* Radio option — account pages don't load checkout.css (where .radio lives), so
   define it here too; otherwise the native input falls to the text baseline. */
.radio { display: inline-flex; align-items: center; gap: 8px; font-size: var(--fs-sm); cursor: pointer; }
.radio input { accent-color: var(--c-accent); width: 18px; height: 18px; flex: none; margin: 0; }
.radio-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-bottom: 4px; }
.radio-grid .radio { align-items: flex-start; line-height: 1.35; }
.radio-grid .radio input { margin-top: 0; }
.return-toggle-box { background: var(--c-grey-100); border-radius: var(--radius); padding: 16px 20px; margin: 20px 0; }
@media (max-width: 768px) { .radio-grid { grid-template-columns: 1fr 1fr; } }

/* ---- Logout confirmation modal ---- */
.logout-modal { display: none; position: fixed; inset: 0; background: rgba(0,0,0,.85); z-index: 999; place-items: center; }
.logout-modal.is-open { display: grid; }
.logout-modal__card { background: #fff; border-radius: var(--radius-lg); padding: 40px 32px; max-width: 360px; width: 90%; text-align: center; }
.logout-modal__card i { font-size: 32px; display: block; margin: 0 auto 20px; }
.logout-modal__card p { font-size: var(--fs-sm); line-height: 1.6; margin-bottom: 28px; font-weight: var(--fw-bold); }

/* ---- Centered message pages (forgot / logout / disconnected) ---- */
.acc-message { max-width: 520px; margin: 0 auto; text-align: center; padding-block: 72px 96px; }
.acc-message__icon { color: var(--c-accent); margin-bottom: 22px; }
.acc-message__icon svg { width: 48px; height: 48px; }
.acc-message h1 { font-size: 22px; font-weight: var(--fw-bold); margin-bottom: 12px; }
.acc-message p { color: var(--c-text-muted); font-size: var(--fs-sm); margin-bottom: 28px; line-height: 1.6; }
.acc-message .field { text-align: left; margin-bottom: 18px; }
.acc-message__link { display: inline-flex; align-items: center; gap: 8px; margin-top: 18px; font-size: var(--fs-sm); font-weight: var(--fw-medium); color: var(--c-text-muted); }
.acc-message__link:hover { color: var(--c-accent); }

/* Font Awesome icon sizing (account contexts) */
.dash-box__icon i { font-size: 20px; }
.acc-head__icon i { font-size: 24px; }
.acc-message__icon i { font-size: 46px; }
.acc-back i { font-size: 13px; }
.addr-box__actions a i, .order-box__link i { font-size: 12px; }
