﻿:root {
  --primary-color: #1b365d;
  --primary-dark: #132742;
  --secondary-color: #2b6cb0;
  --accent-color: #8dc63f;

  --success-color: #11998e;
  --warning-color: #f2a900;
  --danger-color: #eb3349;
  --info-color: #2193b0;

  --text-color: #1f2937;
  --text-muted: #6b7280;
  --surface-color: #ffffff;
  --bg-color: #f5f7fb;
  --border-color: #e5e7eb;

  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 14px;

  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.06);
  --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.1);

  --sidebar-width: 260px;
  --header-height: 60px;
}

/* ── Language Switcher ── */
.lang-switcher {
  display: flex;
  justify-content: flex-end;
  gap: 6px;
  padding: 10px 20px 0;
}

.lang-switcher__btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 3px;
  border: 2px solid var(--border-color);
  border-radius: var(--radius-sm);
  background: var(--surface-color);
  text-decoration: none;
  transition: all 0.2s ease;
  opacity: 0.6;
}

.lang-switcher__btn .lang-flag {
  display: block;
  width: 28px;
  height: 19px;
  object-fit: cover;
  border-radius: 2px;
}

.lang-switcher__btn:hover {
  border-color: var(--secondary-color);
  opacity: 1;
  text-decoration: none;
}

.lang-switcher__btn--active,
.lang-switcher__btn--active:hover {
  border-color: var(--primary-color);
  box-shadow: 0 0 0 1px var(--primary-color);
  opacity: 1;
}

body {
  margin: 0;
  background: var(--bg-color);
  color: var(--text-color);
  font-family: "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 16px;
}

.app-shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: var(--sidebar-width) 1fr;
}

.admin-login-page {
  --primary-color: #e19e62;
  --primary-dark: #c7864f;
  --secondary-color: #f0c8a6;
  --accent-color: #e19e62;
  min-height: 100vh;
  display: grid;
  grid-template-rows: 1fr auto;
  align-items: center;
}

.admin-login-card {
  grid-row: 1;
  justify-self: center;
  width: min(560px, 100%);
  background: #f1f2f3;
  border-color: #dde2e7;
}

.admin-login-footer {
  grid-row: 2;
  width: 100%;
  max-width: none;
  align-self: stretch;
}

.admin-login-page .form-control {
  border-color: #c8d1db;
  background: #fff;
}

.admin-login-page .btn-primary {
  background-color: #8a562e;
  border-color: #8a562e;
}

.admin-login-page .btn-primary:hover,
.admin-login-page .btn-primary:focus {
  background-color: #6f4323;
  border-color: #6f4323;
}

.role-info {
  border-left: 4px solid #c8d1db;
}

.role-info-admin {
  border-left-color: #8a562e;
  background: #fff8f1;
}

.role-info-user {
  border-left-color: #667085;
  background: #f8fafc;
}

.app-shell-public {
  grid-template-columns: 1fr;
  --primary-color: #e19e62;
  --primary-dark: #c7864f;
  --secondary-color: #f0c8a6;
  --accent-color: #e19e62;
}

.app-shell-public .btn-primary {
  background-color: #8a562e;
  border-color: #8a562e;
}

.app-shell-public .btn-primary:hover,
.app-shell-public .btn-primary:focus {
  background-color: #6f4323;
  border-color: #6f4323;
}

.app-shell-public .hero-card {
  background: #d7a175;
}

.app-sidebar {
  background: linear-gradient(180deg, var(--primary-color), var(--secondary-color));
  color: #fff;
  padding: 1rem;
}

.brand-block {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.brand-mark {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.16);
  display: grid;
  place-items: center;
  font-weight: 700;
}

.brand-title {
  font-weight: 600;
}

.brand-subtitle {
  font-size: 14px;
  opacity: 0.85;
}

.app-sidebar .nav-link {
  color: #f3f4f6;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.app-sidebar .nav-link:hover,
.app-sidebar .nav-link.active {
  background: rgba(255, 255, 255, 0.15);
  color: #fff;
}

.app-main {
  min-width: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.app-header {
  height: var(--header-height);
  background: var(--surface-color);
  border-bottom: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 1.5rem;
}

.header-title {
  font-weight: 600;
}

.page-content {
  padding: 1.5rem;
  flex: 1 0 auto;
}

.page-header {
  margin-bottom: 1rem;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 0.75rem;
}

.page-title {
  font-size: 24px;
  font-weight: 600;
  margin: 0;
}

.section-title {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 0.75rem;
}

.claim-form-card {
  background: #f1f2f3;
  border-color: #dde2e7;
}

.claim-form-body {
  padding: 1.2rem;
}

.claim-main-title {
  font-size: 48px;
  line-height: 1.1;
}

.form-section-title {
  font-size: 24px;
  margin-bottom: 0.8rem;
}

.claim-input {
  border-color: #c8d1db;
  background: #fff;
}

.claim-input::placeholder {
  color: #a5afb9;
  opacity: 1;
}

/* Tom Select – country combo-box styling */
.country-select + .ts-wrapper .ts-control {
  border-color: #c8d1db;
  background: #fff;
  min-height: calc(1.5em + 1rem + calc(var(--bs-border-width)* 2));
  font-size: 1.25rem;
  padding: .5rem 1rem;
  border-radius: var(--bs-border-radius-lg);
}
.country-select + .ts-wrapper .ts-control input {
  font-size: 1.25rem;
}
.country-select + .ts-wrapper .ts-dropdown {
  font-size: 1rem;
}
.country-select + .ts-wrapper .ts-dropdown .option.active {
  background: var(--primary-color, #667eea);
  color: #fff;
}
.country-select + .ts-wrapper.disabled .ts-control {
  background-color: #eef2f6 !important;
  color: #5d6670;
}

.shipping-locked {
  background-color: #eef2f6 !important;
  color: #5d6670;
}

.map-label {
  color: #d92d20;
  font-weight: 700;
}

.claim-map {
  width: 100%;
  height: 340px;
  border: 1px solid #c8d1db;
  border-radius: 8px;
  overflow: hidden;
}

.product-section {
  background: rgba(255, 255, 255, 0.45);
  border: 1px solid #d7dee6;
  border-radius: 8px;
  padding: 0.9rem;
}

.add-product-btn {
  background: #d08f58;
  color: #1f2937;
  border: 0;
  font-weight: 600;
}

.add-product-btn:hover,
.add-product-btn:focus {
  background: #bd7c45;
  color: #111827;
}

.claim-info-box {
  background: #fff7ef;
  border: 1px solid #efcfb2;
  color: #3f3f46;
  line-height: 1.55;
}

.upload-progress-wrap .progress {
  height: 10px;
}

.upload-progress-wrap .progress-bar {
  background-color: #8a562e;
}

.rma-chart-canvas {
  width: 100%;
  display: block;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  background: #fff;
}

.card {
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
}

.hero-card {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-lg);
  background: linear-gradient(115deg, var(--primary-color), var(--secondary-color) 55%, var(--accent-color));
  color: #fff;
  min-height: 20vw;
}

/* .hero-card--banner {
  min-height: 320px;
} */

.hero-banner {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: transparent;
}

.hero-content {
  position: relative;
  z-index: 1;
  padding: 2rem;
  max-width: 720px;
}

.confirmation-card {
  max-width: 520px;
  border: 1px solid var(--border-color);
}

.confirmation-number {
  font-size: clamp(1.35rem, 2.4vw, 2rem);
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--primary-dark);
}

.hero-kicker {
  letter-spacing: 0.08em;
  font-size: 13px;
  font-weight: 700;
  opacity: 0.92;
}

.hero-title {
  font-size: 32px;
  font-weight: 700;
  margin-bottom: 0.75rem;
}

.hero-text {
  font-size: 16px;
  max-width: 640px;
}

.benefit-list {
  margin: 0;
  padding-left: 1.2rem;
  display: grid;
  gap: 0.5rem;
}

.contact-item {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.35rem 0;
  font-weight: 500;
}

.contact-item i {
  color: var(--primary-color);
}

.contact-item a {
  color: var(--primary-color);
  text-decoration: none;
}

.contact-item a:hover {
  text-decoration: underline;
}

.sticky-actions {
  position: sticky;
  bottom: 0;
  background: var(--surface-color);
  border-top: 1px solid var(--border-color);
  padding-top: 0.75rem;
  display: flex;
  gap: 0.5rem;
  z-index: 1000;
}

.table thead th {
  text-transform: uppercase;
  font-size: 12px;
  letter-spacing: 0.04em;
  color: var(--text-muted);
}

.form-control:focus,
.form-check-input:focus,
.btn:focus {
  box-shadow: 0 0 0 0.2rem rgba(43, 108, 176, 0.2);
}

.btn-primary {
  background-color: var(--primary-color);
  border-color: var(--primary-color);
}

.btn-primary:hover {
  background-color: var(--primary-dark);
  border-color: var(--primary-dark);
}

.app-footer {
  margin-top: auto;
  padding: 1rem 1.5rem;
  border-top: 1px solid var(--border-color);
  background: var(--surface-color);
}

.footer__credit {
  margin: 0;
  text-align: center;
  color: var(--text-muted);
  font-size: 14px;
}

.footer__credit a {
  color: var(--primary-color);
  text-decoration: none;
  font-weight: 600;
}

.footer__credit a:hover {
  text-decoration: underline;
}

pre {
  margin: 0;
  white-space: pre-wrap;
  background: #0f172a;
  color: #e2e8f0;
  border-radius: var(--radius-sm);
  padding: 1rem;
}

@media (max-width: 991.98px) {
  .app-shell {
    grid-template-columns: 1fr;
  }

  .app-sidebar {
    display: none;
  }

  .page-content {
    padding: 1rem;
  }

  .hero-content {
    padding: 1.25rem;
  }

  .hero-title {
    font-size: 26px;
  }

  .claim-main-title {
    font-size: 34px;
  }

  .form-section-title {
    font-size: 22px;
  }
}

/* ── Full-page submission overlay ── */
.submit-overlay {
  position: fixed;
  inset: 0;
  z-index: 10000;
  display: none;
  align-items: center;
  justify-content: center;
  background: rgba(15, 23, 42, 0.65);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  transition: opacity 0.25s ease;
  opacity: 0;
}

.submit-overlay.active {
  display: flex;
  opacity: 1;
}

.submit-overlay__card {
  background: #fff;
  border-radius: 16px;
  padding: 2.5rem 3rem;
  text-align: center;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  max-width: 380px;
  width: 90%;
  animation: overlaySlideIn 0.35s ease;
}

@keyframes overlaySlideIn {
  from {
    opacity: 0;
    transform: translateY(20px) scale(0.96);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.submit-overlay__spinner {
  width: 56px;
  height: 56px;
  border: 5px solid #e5e7eb;
  border-top-color: var(--primary-color, #8a562e);
  border-radius: 50%;
  animation: overlaySpin 0.8s linear infinite;
  margin: 0 auto 1.25rem;
}

@keyframes overlaySpin {
  to {
    transform: rotate(360deg);
  }
}

.submit-overlay__title {
  font-size: 1.15rem;
  font-weight: 600;
  color: #1e293b;
  margin-bottom: 0.35rem;
}

.submit-overlay__subtitle {
  font-size: 0.875rem;
  color: #64748b;
  margin: 0;
}
