/*
 * StudyBox student store — matches officialstudybox.com.
 * Loaded after panel.css (which provides cards, forms, tables, badges); this file sets the
 * brand (navy / gold / cyan, DM Sans, pill buttons) and the store header, footer and home page.
 */

:root {
  --st-navy: #01213A;
  --st-navy-2: #0b3556;
  --st-gold: #C5880C;
  --st-gold-50: #fdf6e7;
  --st-cyan: #4BC4E0;
  --st-cyan-50: #ecf9fc;
  --st-text: #4D4D4D;
  --st-muted: #808080;
  --st-border: #E5E5E5;
  --st-soft: #F5F5F5;
  --st-pink: #f6d6dd;
  --st-lilac: #c9b3dc;
  --st-rose: #e7a6c4;

  /* Re-point the shared component tokens at the brand. */
  --sb-font: 'DM Sans', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --sb-brand: #01213A;
  --sb-brand-600: #0b3556;
  --sb-brand-50: #eef3f8;
  --sb-brand-100: #d6e2ee;
  --sb-ink: #01213A;
  --sb-ink-2: #666666;
  --sb-ink-3: #999999;
  --sb-bg: #ffffff;
  --sb-border: #E5E5E5;
  --sb-border-strong: #d9d9d9;
  --sb-radius: 14px;
  --sb-shadow: none;
  --bs-primary-rgb: 1, 33, 58;
}

body.store { background: #fff; color: var(--st-text); font-family: var(--sb-font); font-size: 15px; }
.store h1, .store h2, .store h3, .store h4, .store h5 { color: var(--st-navy); font-weight: 700; letter-spacing: -.01em; }

/* Buttons: pill shaped like the website */
.store .btn { border-radius: 999px; padding: 10px 22px; font-weight: 500; }
.store .btn-sm { padding: 6px 14px; }
.store .btn-primary { --bs-btn-bg: var(--st-navy); --bs-btn-border-color: var(--st-navy); --bs-btn-hover-bg: var(--st-navy-2); --bs-btn-hover-border-color: var(--st-navy-2); --bs-btn-active-bg: var(--st-navy-2); --bs-btn-disabled-bg: var(--st-navy); --bs-btn-disabled-border-color: var(--st-navy); }
.store .btn-gold { background: var(--st-gold); border-color: var(--st-gold); color: #fff; }
.store .btn-gold:hover { background: #a9740a; border-color: #a9740a; color: #fff; }
.store .btn-secondary, .store .btn-outline { --bs-btn-color: var(--st-navy); --bs-btn-bg: #fff; --bs-btn-border-color: var(--st-navy); --bs-btn-hover-color: #fff; --bs-btn-hover-bg: var(--st-navy); --bs-btn-hover-border-color: var(--st-navy); }
.store .btn-light-outline { color: #fff; border: 1.5px solid #fff; background: transparent; }
.store .btn-light-outline:hover { background: #fff; color: var(--st-navy); }
.store a:not(.btn):not(.dropdown-item) { color: var(--st-navy); }
.store a:not(.btn):not(.dropdown-item):hover { color: var(--st-gold); }
.store .store-footer a:not(.btn) { color: rgba(255, 255, 255, .72); }
.store .store-footer a:not(.btn):hover { color: var(--st-gold); }
.store .store-footer a.phone, .store .store-footer .social a { color: #fff; }
.eyebrow { color: var(--st-gold); font-size: 12px; font-weight: 600; letter-spacing: .25em; text-transform: uppercase; }

.store-container { max-width: 1290px; margin: 0 auto; padding: 0 20px; }

/* ------------------------------------------------------------------ Header */

.store-topbar { border-bottom: 1px solid var(--st-border); font-size: 13px; color: var(--st-text); }
.store-topbar .store-container { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 42px; }
.store-topbar a { color: var(--st-text); }
.store-topbar a:hover { color: var(--st-gold); }

.store-header { position: sticky; top: 0; z-index: 1030; background: #fff; border-bottom: 1px solid var(--st-border); }
.store-header .store-container { display: flex; align-items: center; gap: 24px; min-height: 84px; }
.store-logo img { height: 64px; width: auto; display: block; }
.store-nav { display: flex; gap: 30px; margin: 0 auto; padding: 0; list-style: none; }
.store-nav a { color: var(--st-navy); font-weight: 500; font-size: 16px; padding: 6px 0; border-bottom: 2px solid transparent; }
.store-nav a:hover, .store-nav a.active { color: var(--st-navy); border-bottom-color: var(--st-gold); }
.store-actions { display: flex; align-items: center; gap: 6px; }
.store-icon {
  position: relative; width: 42px; height: 42px; border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center;
  color: var(--st-navy); font-size: 18px; background: transparent; border: 0;
}
.store-icon:hover { background: var(--st-soft); color: var(--st-navy); }
.store-icon .count {
  position: absolute; top: 2px; right: 0; min-width: 18px; height: 18px; padding: 0 5px;
  border-radius: 999px; background: var(--st-gold); color: #fff; font-size: 11px; font-weight: 700;
  display: inline-flex; align-items: center; justify-content: center;
}
.store-account .dropdown-menu { min-width: 230px; padding: 8px; border: 1px solid var(--st-border); border-radius: 14px; box-shadow: 0 12px 30px rgba(1, 33, 58, .12); }
.store-account .dropdown-item { border-radius: 8px; padding: 9px 12px; display: flex; gap: 10px; align-items: center; color: var(--st-navy); }
.store-account .dropdown-item i { width: 16px; color: var(--st-muted); }
.store-account .dropdown-item:hover { background: var(--st-soft); }
.store-menu-toggle { display: none; }

.store-drawer { display: none; }

@media (max-width: 991.98px) {
  .store-nav { display: none; }
  .store-menu-toggle { display: inline-flex; }
  .store-header .store-container { min-height: 70px; }
  .store-logo img { height: 50px; }
  .store-actions { margin-left: auto; }
  .store-topbar .store-welcome { display: none; }
  .store-drawer.open { display: block; border-top: 1px solid var(--st-border); background: #fff; }
  .store-drawer a { display: block; padding: 12px 20px; color: var(--st-navy); font-weight: 500; border-bottom: 1px solid var(--st-soft); }
}
@media (max-width: 575.98px) { .store-topbar .store-email { display: none; } }

/* ------------------------------------------------------------------ Page content */

.store-main { min-height: 50vh; padding: 36px 0 70px; }
.store-main .page-header h1 { font-size: 30px; }
.store .card { border-color: var(--st-border); border-radius: 16px; box-shadow: none; }
.store .card-header { border-color: var(--st-border); }
.store .card-footer { background: #fafafa; border-color: var(--st-border); }
.store .form-control, .store .form-select { border-radius: 10px; min-height: 46px; border-color: #dcdcdc; }
.store .form-control:focus, .store .form-select:focus { border-color: var(--st-navy); box-shadow: 0 0 0 3px rgba(1, 33, 58, .10); }
.store .stat { box-shadow: none; border-color: var(--st-border); border-radius: 16px; }
.store .tone-brand { background: var(--st-cyan-50); color: #1696b3; }
.store .tone-gold { background: var(--st-gold-50); color: var(--st-gold); }
.store .table > thead th { background: var(--st-soft); color: var(--st-navy); }
.store .login_hide_show { top: 140px; }

.section-title { text-align: center; margin-bottom: 32px; }
.section-title h2 { font-size: 32px; margin: 6px 0 0; }
.section { padding: 60px 0 0; }

/* Hero */
.store-hero { display: grid; grid-template-columns: 1.7fr 1fr; gap: 30px; }
.hero-main {
  position: relative; overflow: hidden; min-height: 440px; border-radius: 4px;
  display: flex; flex-direction: column; justify-content: center; padding: 50px 60px;
  background-size: cover; background-position: center;
}
.hero-main::before { content: ''; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(248, 214, 222, .96) 0%, rgba(248, 214, 222, .82) 45%, rgba(248, 214, 222, .15) 100%); }
.hero-main > * { position: relative; }
.hero-main .kicker { color: var(--st-navy); font-size: 18px; font-weight: 500; }
.hero-main h1 { font-size: 46px; line-height: 1.12; margin: 14px 0 18px; max-width: 520px; }
.hero-main p { color: var(--st-navy); max-width: 460px; }
.hero-side { display: grid; gap: 30px; }
.hero-tile {
  border-radius: 4px; padding: 30px; min-height: 205px; color: #fff;
  display: flex; flex-direction: column; justify-content: center; gap: 6px;
  position: relative; overflow: hidden;
}
.hero-tile small { font-weight: 600; opacity: .95; }
.hero-tile h3 { color: #fff; font-size: 28px; font-weight: 500; margin: 0 0 14px; }
.hero-tile .btn { align-self: flex-start; }
.hero-tile i.bg { position: absolute; right: -10px; bottom: -14px; font-size: 130px; opacity: .22; color: #fff; }
.tile-lilac { background: linear-gradient(135deg, #c3a6dc, #a98bd0); }
.tile-rose  { background: linear-gradient(135deg, #e7a6c4, #d987b2); }
.tile-cyan  { background: linear-gradient(135deg, #67cfe7, #3fb2cf); }

@media (max-width: 991.98px) {
  .store-hero { grid-template-columns: 1fr; }
  .hero-main { min-height: 340px; padding: 36px 28px; }
  .hero-main h1 { font-size: 34px; }
  .hero-side { grid-template-columns: 1fr 1fr; gap: 16px; }
  .hero-tile { min-height: 160px; padding: 22px; }
  .hero-tile h3 { font-size: 22px; }
}
@media (max-width: 575.98px) { .hero-side { grid-template-columns: 1fr; } }

/* Service strip */
.features { display: grid; grid-template-columns: repeat(4, 1fr); padding: 36px 0 0; }
.feature { display: flex; gap: 16px; align-items: center; padding: 6px 20px; border-left: 1px solid var(--st-border); }
.feature:first-child { border-left: 0; }
.feature i { font-size: 28px; color: var(--st-navy); }
.feature strong { display: block; color: var(--st-navy); font-weight: 600; }
.feature span { font-size: 13px; color: var(--st-muted); }
@media (max-width: 991.98px) { .features { grid-template-columns: 1fr 1fr; gap: 18px 0; } .feature:nth-child(3) { border-left: 0; } }
@media (max-width: 575.98px) { .features { grid-template-columns: 1fr; } .feature { border-left: 0; } }

/* Category cards */
.cat-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 24px; }
.cat-card { display: block; text-align: center; color: var(--st-navy); }
.cat-card .cat-img {
  aspect-ratio: 4 / 3; border-radius: 4px; display: flex; align-items: center; justify-content: center;
  font-size: 54px; transition: transform .25s ease;
}
.cat-card:hover .cat-img { transform: translateY(-4px); }
.cat-card h3 { font-size: 18px; margin: 16px 0 2px; font-weight: 600; }
.cat-card span { font-size: 14px; color: var(--st-muted); }
.cat-0 .cat-img { background: #f6e7ea; color: #c9667e; }
.cat-1 .cat-img { background: #e9f4f8; color: #3aa3c0; }
.cat-2 .cat-img { background: #f3ecdc; color: var(--st-gold); }
.cat-3 .cat-img { background: #ece6f5; color: #8a6cb8; }
.cat-4 .cat-img { background: #e7f2ea; color: #4c9a64; }

/* Product cards (home) */
.prod-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 24px; }
.prod-card { border: 1px solid var(--st-border); border-radius: 4px; overflow: hidden; display: flex; flex-direction: column; background: #fff; transition: box-shadow .2s; }
.prod-card:hover { box-shadow: 0 14px 30px rgba(1, 33, 58, .08); }
.prod-card .prod-img { background: var(--st-soft); aspect-ratio: 4 / 3; display: flex; align-items: center; justify-content: center; font-size: 56px; color: var(--st-navy); position: relative; }
.prod-card .prod-img img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; background: #fff; padding: 12px; }
.prod-card .prod-img .tag { z-index: 1; }
.prod-card .tag { position: absolute; top: 12px; left: 12px; background: var(--st-gold); color: #fff; font-size: 11px; font-weight: 700; padding: 4px 10px; border-radius: 999px; letter-spacing: .05em; text-transform: uppercase; }
.prod-card .prod-body { padding: 18px; display: flex; flex-direction: column; gap: 6px; flex: 1; }
.prod-card h3 { font-size: 16px; font-weight: 600; margin: 0; }
.prod-card .price { font-size: 18px; font-weight: 700; color: var(--st-navy); }
.prod-card .price del { font-size: 13px; font-weight: 400; color: var(--st-muted); margin-left: 6px; }
.prod-card .btn { margin-top: auto; }

/* Promo banner */
.promo { background: var(--st-navy); border-radius: 4px; color: #fff; padding: 44px 50px; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 20px; }
.promo h2 { color: #fff; font-size: 30px; margin: 6px 0; }
.promo p { color: rgba(255, 255, 255, .75); margin: 0; }

/* ------------------------------------------------------------------ Account area */

.account-layout { display: grid; grid-template-columns: 270px 1fr; gap: 32px; align-items: start; }
.account-nav { border: 1px solid var(--st-border); border-radius: 16px; overflow: hidden; position: sticky; top: 110px; }
.account-nav .who { padding: 20px; background: var(--st-soft); display: flex; gap: 12px; align-items: center; }
.account-nav .who .app-avatar { width: 44px; height: 44px; background: var(--st-navy); color: #fff; font-size: 16px; }
.account-nav .who strong { display: block; color: var(--st-navy); }
.account-nav .who span { font-size: 13px; color: var(--st-muted); word-break: break-all; }
.account-nav a { display: flex; gap: 12px; align-items: center; padding: 13px 20px; color: var(--st-navy); border-top: 1px solid var(--st-border); font-weight: 500; }
.account-nav a i { width: 18px; color: var(--st-muted); }
.account-nav a.active { background: var(--st-gold-50); box-shadow: inset 3px 0 0 var(--st-gold); }
.account-nav a.active i { color: var(--st-gold); }
.account-nav a:hover { background: var(--st-soft); color: var(--st-navy); }
@media (max-width: 991.98px) { .account-layout { grid-template-columns: 1fr; } .account-nav { position: static; } }

/* ------------------------------------------------------------------ Footer */

.store-footer { background: var(--st-navy); color: rgba(255, 255, 255, .72); padding: 64px 0 0; font-size: 14px; }
.store-footer h4 { color: #fff; font-size: 17px; font-weight: 600; margin-bottom: 18px; }
.store-footer a { color: rgba(255, 255, 255, .72); }
.store-footer a:hover { color: var(--st-gold); }
.store-footer ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.store-footer .foot-logo { width: 56px; background: #fff; border-radius: 12px; padding: 6px; margin-bottom: 16px; }
.store-footer .social { display: flex; gap: 10px; margin-top: 18px; }
.store-footer .social a { width: 38px; height: 38px; border-radius: 50%; border: 1px solid rgba(255, 255, 255, .25); display: inline-flex; align-items: center; justify-content: center; color: #fff; }
.store-footer .social a:hover { background: var(--st-gold); border-color: var(--st-gold); }
.store-footer .phone { color: #fff; font-size: 20px; font-weight: 600; }
.store-footer .copy { border-top: 1px solid rgba(255, 255, 255, .12); margin-top: 48px; padding: 20px 0; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px; font-size: 13px; }

/* ------------------------------------------------------------------ Sign-in pages inside the store */

.store-auth { max-width: 460px; margin: 10px auto 0; }
.store-auth .card-body { padding: 36px; }
.store-auth h1 { font-size: 28px; text-align: center; margin-bottom: 6px; }
.store-auth .sub { text-align: center; color: var(--st-muted); margin-bottom: 26px; }
.store-auth .btn-primary { width: 100%; min-height: 48px; }
.store-auth .auth-foot { text-align: center; margin-top: 20px; }
