/* YS TRADING CARDS UK - Official E-Commerce & Machine-Audit Layout */
:root {
  --primary: #1e3a8a;
  --primary-dark: #172554;
  --secondary: #0284c7;
  --dark: #0f172a;
  --gray-900: #111827;
  --gray-800: #1f2937;
  --gray-700: #374151;
  --gray-600: #4b5563;
  --gray-200: #e5e7eb;
  --gray-100: #f3f4f6;
  --gray-50: #f9fafb;
  --white: #ffffff;
  --success: #15803d;
  --success-bg: #dcfce7;
  --border: #d1d5db;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  color: var(--gray-900);
  background-color: var(--gray-50);
  line-height: 1.6;
  font-size: 15px;
}

/* Machine-Scan Verification Banner */
.gov-top-bar {
  background-color: #0b1d3a;
  color: #f1f5f9;
  padding: 8px 24px;
  font-size: 13px;
  border-bottom: 2px solid #3b82f6;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}

.gov-top-bar a {
  color: #93c5fd;
  text-decoration: none;
}

.gov-top-bar .badge {
  background-color: #1e293b;
  border: 1px solid #475569;
  padding: 2px 8px;
  border-radius: 4px;
  font-weight: 600;
  color: #38bdf8;
}

/* Header & Nav */
header {
  background-color: var(--white);
  border-bottom: 1px solid var(--gray-200);
  padding: 16px 32px;
}

.header-container {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.brand-title {
  font-size: 24px;
  font-weight: 800;
  color: var(--primary-dark);
  letter-spacing: -0.5px;
}

.brand-subtitle {
  font-size: 13px;
  color: var(--gray-600);
  font-weight: 500;
}

nav ul {
  display: flex;
  list-style: none;
  gap: 20px;
}

nav a {
  color: var(--gray-700);
  text-decoration: none;
  font-weight: 600;
  font-size: 14px;
  padding: 6px 12px;
  border-radius: 6px;
  transition: all 0.2s;
}

nav a:hover, nav a.active {
  background-color: var(--gray-100);
  color: var(--primary);
}

/* Container */
.container {
  max-width: 1200px;
  margin: 24px auto;
  padding: 0 20px;
}

/* Machine-Readable Table Component */
.table-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 24px;
  margin-bottom: 28px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

.table-card h2 {
  font-size: 20px;
  color: var(--primary-dark);
  margin-bottom: 16px;
  padding-bottom: 8px;
  border-bottom: 2px solid var(--primary);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.audit-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  font-size: 14px;
}

.audit-table th {
  background-color: #f1f5f9;
  color: var(--gray-800);
  padding: 12px 16px;
  font-weight: 700;
  border: 1px solid var(--gray-200);
  text-transform: uppercase;
  font-size: 12px;
  letter-spacing: 0.5px;
}

.audit-table td {
  padding: 12px 16px;
  border: 1px solid var(--gray-200);
  color: var(--gray-800);
}

.audit-table tr:nth-child(even) {
  background-color: var(--gray-50);
}

.audit-table tr:hover {
  background-color: #eff6ff;
}

.tag-active {
  display: inline-block;
  background-color: var(--success-bg);
  color: var(--success);
  padding: 3px 8px;
  border-radius: 4px;
  font-weight: 700;
  font-size: 12px;
  border: 1px solid #86efac;
}

/* Hero Product Section */
.hero-product-grid {
  display: grid;
  grid-template-columns: 380px 1fr;
  gap: 32px;
  align-items: start;
}

.hero-img-box {
  background: #ffffff;
  border: 2px solid var(--gray-200);
  border-radius: 12px;
  padding: 16px;
  text-align: center;
  box-shadow: 0 4px 6px -1px rgba(0,0,0,0.1);
}

.hero-img-box img {
  max-width: 100%;
  height: auto;
  border-radius: 8px;
}

.hero-details h3 {
  font-size: 24px;
  color: var(--primary-dark);
  margin-bottom: 8px;
}

.psa-badge {
  display: inline-block;
  background: #dc2626;
  color: #fff;
  padding: 4px 12px;
  border-radius: 4px;
  font-weight: 800;
  font-size: 14px;
  margin-bottom: 16px;
  letter-spacing: 0.5px;
}

.spec-list {
  list-style: none;
  margin-bottom: 20px;
}

.spec-list li {
  padding: 8px 0;
  border-bottom: 1px dashed var(--gray-200);
  display: flex;
  justify-content: space-between;
}

.spec-list .label {
  color: var(--gray-600);
  font-weight: 600;
}

.spec-list .val {
  color: var(--gray-900);
  font-weight: 700;
}

/* Catalog Grid */
.catalog-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 20px;
}

.card-item {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 16px;
  text-align: center;
  box-shadow: 0 1px 3px rgba(0,0,0,0.05);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.card-item img {
  max-width: 100%;
  height: 250px;
  object-fit: contain;
  margin-bottom: 12px;
  border-radius: 6px;
}

.card-title {
  font-size: 15px;
  font-weight: 700;
  color: var(--gray-900);
  margin-bottom: 6px;
}

.card-grade {
  font-size: 12px;
  font-weight: 700;
  color: #b91c1c;
  background: #fee2e2;
  padding: 2px 8px;
  border-radius: 4px;
  display: inline-block;
  margin-bottom: 8px;
}

.card-price {
  font-size: 18px;
  font-weight: 800;
  color: var(--primary-dark);
}

/* Review Component */
.review-score-box {
  display: flex;
  gap: 24px;
  align-items: center;
  padding: 20px;
  background: #f0fdf4;
  border: 1px solid #bbf7d0;
  border-radius: 8px;
  margin-bottom: 24px;
}

.review-stars {
  color: #16a34a;
  font-size: 28px;
  font-weight: 900;
}

.review-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 16px;
  margin-bottom: 16px;
}

.review-header {
  display: flex;
  justify-content: space-between;
  margin-bottom: 8px;
  font-size: 14px;
}

.verified-buyer {
  color: var(--success);
  font-weight: 600;
}

/* Footer */
footer {
  background: #0f172a;
  color: #94a3b8;
  padding: 36px 20px;
  font-size: 13px;
  margin-top: 60px;
  border-top: 4px solid var(--primary);
}

.footer-content {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 32px;
}

.footer-col h4 {
  color: #f8fafc;
  margin-bottom: 12px;
  font-size: 15px;
}

.footer-bottom {
  max-width: 1200px;
  margin: 24px auto 0;
  padding-top: 16px;
  border-top: 1px solid #334155;
  text-align: center;
  font-size: 12px;
}
