/* =========================================
   VELOURA — CUSTOMER ACCOUNT PORTAL
   White / ivory / gold (matches site theme)
========================================= */

/* =========================================
   ACCOUNT LAYOUT
========================================= */

.account-layout {
  display: grid;
  grid-template-columns: 280px 1fr;
  min-height: calc(100vh - 80px);
  gap: 0;
  padding-top: 80px;
  background: var(--bg-2);
}

.account-sidebar {
  background: #fff;
  border-right: 1px solid var(--border);
  padding: 40px 0;
  position: sticky;
  top: 80px;
  height: calc(100vh - 80px);
  overflow-y: auto;
}

.account-content {
  padding: 48px 56px;
  background: var(--bg-2);
  min-height: calc(100vh - 80px);
}

/* =========================================
   SIDEBAR
========================================= */

.account-sidebar-profile {
  padding: 0 28px 32px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 24px;
}

.account-sidebar-avatar {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--gold-line);
  border: 2px solid var(--gold);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  font-weight: 600;
  font-family: 'Playfair Display', serif;
  color: var(--gold-2);
  margin-bottom: 14px;
}

.account-sidebar-name {
  font-family: 'Playfair Display', serif;
  font-size: 16px;
  font-weight: 600;
  color: var(--black);
  margin-bottom: 4px;
}

.account-sidebar-tag {
  font-size: 11px;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--gold-2);
}

.account-nav-section {
  padding: 0 16px 20px;
}

.account-nav-title {
  font-size: 10px;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--muted);
  padding: 0 12px 8px;
  margin-bottom: 4px;
}

.account-nav-link {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  border-radius: 8px;
  font-size: 13.5px;
  color: var(--text);
  transition: all .2s ease;
  text-decoration: none;
  margin-bottom: 2px;
}

.account-nav-link:hover {
  background: var(--bg-2);
  color: var(--black);
}

.account-nav-link.active {
  background: var(--gold-line);
  color: var(--black);
  border-left: 3px solid var(--gold);
}

.account-nav-link .nav-icon {
  width: 18px;
  height: 18px;
  opacity: .6;
  flex-shrink: 0;
}

.account-nav-link.active .nav-icon,
.account-nav-link:hover .nav-icon {
  opacity: 1;
}

.account-nav-link.logout-link {
  color: var(--danger);
  margin-top: 8px;
}

.account-nav-link.logout-link:hover {
  background: rgba(198,40,40,.08);
  color: #C62828;
}

/* =========================================
   PAGE HEADER
========================================= */

.account-page-header {
  margin-bottom: 40px;
  padding-bottom: 28px;
  border-bottom: 1px solid var(--border);
}

.account-page-header h1 {
  font-family: 'Playfair Display', serif;
  font-size: 32px;
  font-weight: 600;
  color: var(--black);
  margin-bottom: 8px;
}

.account-page-header p {
  color: var(--muted);
  font-size: 14px;
}

/* =========================================
   DASHBOARD WIDGETS
========================================= */

.dashboard-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  margin-bottom: 36px;
}

.dashboard-widget {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 28px 24px;
  transition: all .3s ease;
  position: relative;
  overflow: hidden;
}

.dashboard-widget::before {
  content: '';
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 3px;
  background: linear-gradient(90deg, var(--gold), transparent);
  opacity: 0;
  transition: opacity .3s;
}

.dashboard-widget:hover {
  border-color: var(--gold);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md, 0 12px 36px rgba(0,0,0,.08));
}

.dashboard-widget:hover::before {
  opacity: 1;
}

.widget-icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: var(--gold-line);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
}

.widget-icon svg {
  width: 20px;
  height: 20px;
  color: var(--gold-2);
}

.widget-number {
  font-family: 'Playfair Display', serif;
  font-size: 28px;
  font-weight: 700;
  color: var(--black);
  line-height: 1;
  margin-bottom: 8px;
}

.widget-label {
  font-size: 12px;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--muted);
}

/* =========================================
   ACCOUNT CARDS
========================================= */

.account-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 16px;
  margin-bottom: 24px;
  overflow: hidden;
}

.account-card-header {
  padding: 24px 28px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.account-card-title {
  font-family: 'Playfair Display', serif;
  font-size: 18px;
  font-weight: 600;
  color: var(--black);
}

.account-card-body {
  padding: 28px;
}

/* =========================================
   FORMS
========================================= */

.account-form .form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-bottom: 20px;
}

.account-form .form-group {
  margin-bottom: 20px;
}

.account-form label {
  display: block;
  font-size: 12px;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 10px;
}

.account-form input,
.account-form textarea,
.account-form select {
  width: 100%;
  background: #fff;
  border: 1px solid var(--border);
  color: var(--text);
  padding: 14px 18px;
  border-radius: 10px;
  font-size: 14px;
  transition: border-color .2s;
}

.account-form input:focus,
.account-form textarea:focus,
.account-form select:focus {
  outline: none;
  border-color: var(--gold);
}

.account-form .form-actions {
  display: flex;
  gap: 14px;
  padding-top: 10px;
}

/* =========================================
   TABLES
========================================= */

.account-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

.account-table th {
  text-align: left;
  font-size: 11px;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--muted);
  padding: 14px 16px;
  border-bottom: 1px solid var(--border);
}

.account-table td {
  padding: 16px;
  border-bottom: 1px solid var(--border);
  color: var(--text);
  vertical-align: middle;
}

.account-table tr:last-child td {
  border-bottom: none;
}

.account-table tr:hover td {
  background: var(--bg-2);
}

/* =========================================
   STATUS BADGES
========================================= */

.status-badge {
  display: inline-block;
  padding: 4px 12px;
  border-radius: 100px;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: .5px;
  text-transform: capitalize;
}

.status-active    { background: rgba(46,204,113,.1); color: #1F9D55; }
.status-pending   { background: rgba(243,156,18,.1); color: #B45309; }
.status-shipped   { background: rgba(52,152,219,.1); color: #1D4ED8; }
.status-confirmed { background: rgba(46,204,113,.1); color: #1F9D55; }
.status-cancelled { background: rgba(231,76,60,.1);  color: #DC2626; }
.status-transferred { background: var(--gold-line); color: var(--gold-2); }

/* =========================================
   WISHLIST GRID
========================================= */

.wishlist-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px,1fr));
  gap: 20px;
}

.wishlist-item {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
  transition: all .25s ease;
}

.wishlist-item:hover {
  border-color: var(--gold);
  transform: translateY(-2px);
}

.wishlist-item-img {
  aspect-ratio: 1;
  background: var(--bg-3);
  display: flex;
  align-items: center;
  justify-content: center;
}

.wishlist-item-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.wishlist-item-body {
  padding: 16px;
}

.wishlist-item-name {
  font-size: 14px;
  font-weight: 500;
  color: var(--black);
  margin-bottom: 6px;
}

.wishlist-item-price {
  font-size: 13px;
  color: var(--gold-2);
  margin-bottom: 12px;
}

.wishlist-item-actions {
  display: flex;
  gap: 8px;
}

/* =========================================
   EDITION CARDS
========================================= */

.edition-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 24px;
  display: flex;
  gap: 20px;
  align-items: flex-start;
  margin-bottom: 16px;
  transition: border-color .2s;
}

.edition-card:hover {
  border-color: var(--gold);
}

.edition-card-img {
  width: 80px;
  height: 80px;
  border-radius: 10px;
  background: var(--bg-3);
  flex-shrink: 0;
  overflow: hidden;
}

.edition-card-img img {
  width: 100%; height: 100%;
  object-fit: cover;
}

.edition-card-info {
  flex: 1;
}

.edition-card-title {
  font-family: 'Playfair Display', serif;
  font-size: 16px;
  font-weight: 600;
  color: var(--black);
  margin-bottom: 6px;
}

.edition-card-serial {
  font-size: 12px;
  color: var(--gold-2);
  letter-spacing: 1px;
  margin-bottom: 12px;
  font-family: monospace;
}

.edition-card-meta {
  display: flex;
  gap: 20px;
}

.edition-meta-item {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.edition-meta-label {
  font-size: 10px;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--muted);
}

.edition-meta-value {
  font-size: 13px;
  color: var(--text);
}

/* =========================================
   CERTIFICATE CARD
========================================= */

.certificate-card {
  background: linear-gradient(135deg, #fff 0%, var(--bg-3) 100%);
  border: 1px solid var(--gold-line);
  border-radius: 16px;
  padding: 28px;
  position: relative;
  overflow: hidden;
  margin-bottom: 16px;
}

.certificate-card::before {
  content: 'AUTHENTICATED';
  position: absolute;
  top: 24px; right: -30px;
  background: var(--gold);
  color: #fff;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 2px;
  padding: 6px 40px;
  transform: rotate(45deg) translateX(20px);
}

.certificate-number {
  font-family: monospace;
  font-size: 14px;
  color: var(--gold-2);
  letter-spacing: 2px;
  margin-bottom: 10px;
}

.certificate-product {
  font-family: 'Playfair Display', serif;
  font-size: 18px;
  font-weight: 600;
  color: var(--black);
  margin-bottom: 16px;
}

.certificate-meta {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

/* =========================================
   NOTIFICATIONS TOGGLE
========================================= */

.notification-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 0;
  border-bottom: 1px solid var(--border);
}

.notification-row:last-child {
  border-bottom: none;
}

.notification-info h4 {
  font-size: 14px;
  font-weight: 500;
  color: var(--black);
  margin-bottom: 4px;
}

.notification-info p {
  font-size: 12px;
  color: var(--muted);
}

.toggle-switch {
  position: relative;
  width: 48px;
  height: 26px;
  cursor: pointer;
}

.toggle-switch input {
  opacity: 0;
  width: 0; height: 0;
}

.toggle-track {
  position: absolute;
  inset: 0;
  background: var(--bg-3);
  border: 1px solid var(--border);
  border-radius: 100px;
  transition: background .2s;
}

.toggle-track::after {
  content: '';
  position: absolute;
  width: 18px; height: 18px;
  top: 3px; left: 3px;
  background: #fff;
  box-shadow: 0 1px 3px rgba(0,0,0,.15);
  border-radius: 50%;
  transition: transform .2s, background .2s;
}

.toggle-switch input:checked + .toggle-track {
  background: var(--gold-line);
  border: 1px solid var(--gold);
}

.toggle-switch input:checked + .toggle-track::after {
  transform: translateX(22px);
  background: var(--gold);
}

/* =========================================
   EMPTY STATES
========================================= */

.empty-state {
  text-align: center;
  padding: 60px 40px;
}

.empty-state-icon {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: var(--gold-line);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 20px;
}

.empty-state-icon svg {
  width: 28px; height: 28px;
  color: var(--gold-2);
}

.empty-state h3 {
  font-family: 'Playfair Display', serif;
  font-size: 18px;
  color: var(--black);
  margin-bottom: 8px;
}

.empty-state p {
  font-size: 14px;
  color: var(--muted);
  margin-bottom: 24px;
}

/* =========================================
   BUTTONS
========================================= */

.btn-burgundy {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 28px;
  background: var(--gold);
  color: #fff;
  border: none;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: .5px;
  cursor: pointer;
  transition: all .2s;
  text-decoration: none;
}

.btn-burgundy:hover {
  background: var(--gold-2);
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(201,169,110,.35);
}

.btn-outline-burgundy {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 28px;
  background: transparent;
  color: var(--gold-2);
  border: 1px solid var(--gold);
  border-radius: 8px;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  transition: all .2s;
  text-decoration: none;
}

.btn-outline-burgundy:hover {
  background: var(--gold-line);
  color: var(--black);
}

.btn-sm-ghost {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  background: var(--bg-2);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: 6px;
  font-size: 12px;
  cursor: pointer;
  transition: all .2s;
  text-decoration: none;
}

.btn-sm-ghost:hover {
  background: var(--gold-line);
  border-color: var(--gold);
  color: var(--black);
}

/* =========================================
   ACCOUNT AUTH PAGES (login/register)
========================================= */

.auth-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 120px 24px 80px;
  background: var(--bg-2);
}

.auth-card {
  width: 100%;
  max-width: 460px;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 48px 44px;
}

.auth-logo {
  text-align: center;
  margin-bottom: 32px;
  font-family: 'Playfair Display', serif;
  font-size: 24px;
  letter-spacing: 4px;
  color: var(--black);
}

.auth-logo span {
  color: var(--gold-2);
}

.auth-title {
  font-family: 'Playfair Display', serif;
  font-size: 28px;
  text-align: center;
  color: var(--black);
  margin-bottom: 8px;
}

.auth-subtitle {
  text-align: center;
  color: var(--muted);
  font-size: 14px;
  margin-bottom: 32px;
}

.auth-divider {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 24px 0;
  color: var(--muted);
  font-size: 12px;
}

.auth-divider::before,
.auth-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border);
}

.auth-footer {
  text-align: center;
  margin-top: 24px;
  font-size: 14px;
  color: var(--muted);
}

.auth-footer a {
  color: var(--gold-2);
  text-decoration: underline;
}

/* =========================================
   RESPONSIVE
========================================= */

@media (max-width: 1024px) {
  .account-layout {
    grid-template-columns: 1fr;
  }

  .account-sidebar {
    position: static;
    height: auto;
    border-right: none;
    border-bottom: 1px solid var(--border);
    padding: 24px 0;
  }

  .account-content {
    padding: 32px 24px;
  }

  .dashboard-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 640px) {
  .dashboard-grid {
    grid-template-columns: 1fr 1fr;
    gap: 14px;
  }

  .account-form .form-row {
    grid-template-columns: 1fr;
  }

  .account-card-body {
    padding: 20px;
  }
}
