/* KYMI Printer Specific Styles (Extends tokens.css & layout.css) */

/* Language Switcher */
.lang-switch {
  display: inline-flex;
  align-items: center;
  background: var(--wash);
  border: 1px solid var(--line);
  border-radius: 9px;
  padding: 2px;
  gap: 2px;
  flex-shrink: 0;
}
.lang-switch a {
  font-size: 11px;
  font-weight: 800;
  padding: 5px 9px;
  border-radius: 7px;
  color: var(--text-muted);
  transition: all .15s;
}
.lang-switch a:hover {
  color: var(--primary);
}
.lang-switch a.active {
  background: white;
  color: var(--primary);
  box-shadow: 0 2px 6px rgba(40, 52, 91, .08);
}

/* OS Detection Banner — Clean Single-Line Bar */
.os-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
  background: linear-gradient(135deg, #eff2fe 0%, #f5f3ff 100%);
  border: 1px solid #d7dffc;
  border-radius: var(--radius-md);
  padding: 10px 18px;
  margin-bottom: 24px;
}
.os-banner-left {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}
.os-icon {
  width: 32px;
  height: 32px;
  border-radius: 9px;
  background: white;
  border: 1px solid #dbe2fc;
  display: grid;
  place-items: center;
  font-size: 16px;
  flex-shrink: 0;
}
.os-banner-text {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.4;
}
.os-banner-text strong {
  color: var(--navy);
  font-size: 14px;
}
.os-banner-sep {
  color: #cbd5e1;
}
.os-banner-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}
.os-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 800;
  background: var(--success-bg);
  color: var(--success);
}

/* Brand Grid — Single Clean 7-Column Row on Desktop */
.brand-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 12px;
  margin: 16px 0 28px;
}
@media (max-width: 1100px) {
  .brand-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
  .brand-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
}
.brand-card {
  background: white;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: 15px 14px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  transition: all .18s ease;
  text-align: left;
  min-width: 0;
}
.brand-card:hover {
  border-color: var(--primary);
  box-shadow: 0 10px 26px rgba(82, 101, 232, .1);
  transform: translateY(-2px);
}
.brand-card-name {
  font-size: 15px;
  font-weight: 800;
  color: var(--navy);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  white-space: nowrap;
}
.brand-card-sub {
  font-size: 12px;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.brand-card-count {
  font-size: 11px;
  font-weight: 700;
  color: var(--primary);
  background: var(--primary-light);
  padding: 2px 7px;
  border-radius: 999px;
  flex-shrink: 0;
}

/* Universal Driver Compact Banner */
.universal-strip {
  background: linear-gradient(135deg, #17233c 0%, #273761 100%);
  color: white;
  border-radius: var(--radius);
  padding: 20px 24px;
  margin-bottom: 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  flex-wrap: wrap;
  box-shadow: var(--shadow-sm);
}
.universal-strip-copy {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.universal-strip-title {
  font-size: 16px;
  font-weight: 800;
  display: flex;
  align-items: center;
  gap: 8px;
}
.universal-strip-desc {
  font-size: 13px;
  color: #cbd5e1;
  margin: 0;
}
.universal-pills {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}
.universal-pill-btn {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 7px 12px;
  border-radius: 9px;
  background: rgba(255, 255, 255, .12);
  border: 1px solid rgba(255, 255, 255, .2);
  color: white !important;
  font-size: 12px;
  font-weight: 700;
  transition: all .15s;
  white-space: nowrap;
}
.universal-pill-btn:hover {
  background: var(--primary);
  border-color: var(--primary);
  transform: translateY(-1px);
}
.universal-pill-cta {
  background: #5265e8;
  border-color: #6b7cff;
}

/* Breadcrumbs */
.breadcrumbs {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  font-size: 13px;
  color: var(--text-muted);
  padding: 20px 0 12px;
}
.breadcrumbs a:hover {
  color: var(--primary);
  text-decoration: underline;
}
.breadcrumbs span[aria-current="page"] {
  color: var(--navy);
  font-weight: 700;
}

/* Detail Page Layout */
.detail-header {
  background: white;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 28px;
  box-shadow: var(--shadow-sm);
  margin-bottom: 24px;
}
.detail-badges {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 12px;
}
.detail-title {
  font-size: clamp(22px, 3.2vw, 32px);
  font-weight: 800;
  color: var(--navy);
  margin: 0 0 10px;
  line-height: 1.3;
  letter-spacing: -.02em;
}
.detail-sub {
  font-size: 15px;
  color: var(--text-muted);
  margin: 0 0 18px;
}
.spec-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}
.spec-chip {
  background: var(--wash);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 8px 14px;
  font-size: 13px;
  color: var(--text);
}
.spec-chip small {
  display: block;
  font-size: 11px;
  color: var(--muted);
  font-weight: 700;
}
.spec-chip strong {
  color: var(--navy);
}

/* Content Card & Tables (Driverscape + NoDevice hybrid) */
.content-section {
  background: white;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 26px 28px;
  box-shadow: var(--shadow-sm);
  margin-bottom: 24px;
}
.section-title {
  font-size: 19px;
  font-weight: 800;
  color: var(--navy);
  margin: 0 0 14px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.table-wrap {
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: 12px;
}
.driver-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
  text-align: left;
}
.driver-table th {
  background: var(--wash);
  color: var(--navy);
  font-weight: 800;
  padding: 12px 14px;
  border-bottom: 1px solid var(--line);
  white-space: nowrap;
}
.driver-table td {
  padding: 13px 14px;
  border-bottom: 1px solid var(--line);
  vertical-align: middle;
}
.driver-table tr:last-child td {
  border-bottom: 0;
}
.driver-table tr.os-recommended {
  background: #f5f7ff;
}
.os-match-tag {
  display: inline-block;
  margin-left: 6px;
  padding: 2px 7px;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 800;
  background: var(--primary);
  color: white;
}

/* Primary Action Buttons */
.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 18px;
  border-radius: 10px;
  background: var(--primary);
  color: white !important;
  font-size: 13px;
  font-weight: 700;
  border: 0;
  transition: all .15s;
  white-space: nowrap;
}
.btn-primary:hover {
  background: var(--primary-hover);
  transform: translateY(-1px);
  box-shadow: 0 6px 16px rgba(82, 101, 232, .25);
}
.btn-outline {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 16px;
  border-radius: 10px;
  background: white;
  color: var(--navy);
  border: 1px solid var(--line);
  font-size: 13px;
  font-weight: 700;
  transition: all .15s;
  white-space: nowrap;
}
.btn-outline:hover {
  border-color: var(--primary);
  color: var(--primary);
  background: var(--primary-light);
}

/* Step List & Troubleshooting */
.step-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 14px;
  list-style: none;
  padding: 0;
  margin: 0;
}
.step-card {
  background: var(--wash);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 16px;
}
.step-num {
  display: inline-grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border-radius: 8px;
  background: var(--primary);
  color: white;
  font-size: 12px;
  font-weight: 800;
  margin-bottom: 8px;
}
.step-card h3 {
  font-size: 15px;
  color: var(--navy);
  margin: 0 0 6px;
}
.step-card p {
  font-size: 13px;
  color: var(--text-muted);
  margin: 0;
  line-height: 1.55;
}

/* Error Code Grid */
.error-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
  gap: 14px;
}
.error-card {
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 16px;
  background: #fcfdff;
}
.error-code-badge {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 800;
  color: var(--error);
  background: var(--error-bg);
  padding: 3px 9px;
  border-radius: 6px;
  margin-bottom: 8px;
}
.error-card h3 {
  font-size: 15px;
  color: var(--navy);
  margin: 0 0 6px;
}
.error-card p {
  font-size: 13px;
  color: var(--text-muted);
  margin: 0;
  line-height: 1.55;
}

/* FAQ Accordion */
.faq-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.faq-item {
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--wash);
  padding: 14px 18px;
}
.faq-item summary {
  font-size: 15px;
  font-weight: 700;
  color: var(--navy);
  cursor: pointer;
}
.faq-item p {
  margin: 10px 0 0;
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.65;
}

/* Test Print Lab Styles */
.test-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 20px;
}
.test-sheet-preview {
  background: white;
  border: 2px dashed var(--line);
  border-radius: 16px;
  padding: 28px;
  margin-top: 16px;
}
.cmyk-bars {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
  margin: 20px 0;
}
.cmyk-bar {
  height: 120px;
  border-radius: 10px;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding: 10px;
  font-weight: 800;
  font-size: 14px;
}
.bar-c { background: #00aeef; color: white; }
.bar-m { background: #ec008c; color: white; }
.bar-y { background: #fff200; color: #111; border: 1px solid #e5d800; }
.bar-k { background: #111111; color: white; }

.gradient-strip {
  height: 36px;
  border-radius: 8px;
  margin: 10px 0;
}
.grad-gray { background: linear-gradient(90deg, #000000 0%, #ffffff 100%); border: 1px solid #ddd; }
.grad-rgb { background: linear-gradient(90deg, #ff0000 0%, #ffff00 20%, #00ff00 40%, #00ffff 60%, #0000ff 80%, #ff00ff 100%); }

.grid-pattern {
  border: 2px solid #111;
  padding: 16px;
  margin-top: 16px;
  background-image: linear-gradient(to right, #e2e8f0 1px, transparent 1px), linear-gradient(to bottom, #e2e8f0 1px, transparent 1px);
  background-size: 20px 20px;
}

/* Official Disclaimer Box */
.official-notice {
  background: #fffbeb;
  border: 1px solid #fde68a;
  color: #92400e;
  border-radius: 12px;
  padding: 14px 18px;
  font-size: 13px;
  line-height: 1.6;
  margin-top: 16px;
}

/* Print Media Mode for Browser Test Print Lab */
@media print {
  .site-header, .mobile-nav, .breadcrumbs, .site-footer, .no-print, .ad-slot-container {
    display: none !important;
  }
  body {
    background: white !important;
    margin: 0 !important;
  }
  .container {
    max-width: 100% !important;
    padding: 0 !important;
  }
  .test-sheet-preview {
    border: 0 !important;
    padding: 0 !important;
    margin: 0 !important;
  }
  * {
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
  }
}

@media (max-width: 768px) {
  .detail-header, .content-section { padding: 18px; }
  .cmyk-bars { grid-template-columns: repeat(2, 1fr); }
}
