/* =====================================================================
   TEXRON — The Unlimited Lubricant
   Design System & Base Styles
   Palet turunan logo: biru #022f7f, merah #e6080e, kuning #fec801
   ===================================================================== */

/* ---------------------------------------------------------------------
   1. TOKEN
   --------------------------------------------------------------------- */
:root {
  /* Warna merek */
  --brand-blue:        #022f7f;
  --brand-blue-700:    #04246a;
  --brand-blue-900:    #011a4d;
  --brand-blue-300:    #3a63b0;
  --brand-blue-100:    #e8eefa;

  --brand-red:         #e6080e;
  --brand-red-700:     #c00609;
  --brand-red-100:     #fdeaea;

  --brand-yellow:      #fec801;
  --brand-yellow-600:  #d9a800;
  --brand-yellow-100:  #fff7dd;

  /* Netral */
  --ink:               #14181f;
  --ink-soft:          #434b59;
  --ink-muted:         #6b7482;
  --line:              #e2e6ed;
  --line-soft:         #eef1f6;
  --surface:           #ffffff;
  --surface-alt:       #f6f8fb;
  --surface-dark:      #0b1f47;

  /* Status */
  --success:           #0f8a4d;
  --warning:           #b8820a;
  --danger:            #c00609;

  /* Tipografi */
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Arial, sans-serif;
  --font-head: 'Barlow Condensed', 'Inter', sans-serif;

  --fs-xs:   0.75rem;
  --fs-sm:   0.875rem;
  --fs-base: 1rem;
  --fs-lg:   1.125rem;
  --fs-xl:   1.375rem;
  --fs-2xl:  1.75rem;
  --fs-3xl:  2.25rem;
  --fs-4xl:  3rem;

  /* Spasi */
  --sp-1: 0.25rem;
  --sp-2: 0.5rem;
  --sp-3: 0.75rem;
  --sp-4: 1rem;
  --sp-5: 1.5rem;
  --sp-6: 2rem;
  --sp-7: 3rem;
  --sp-8: 4rem;
  --sp-9: 6rem;

  /* Bentuk */
  --radius-sm: 3px;
  --radius:    6px;
  --radius-lg: 10px;

  --shadow-sm: 0 1px 2px rgba(2, 47, 127, .06);
  --shadow:    0 2px 10px rgba(2, 47, 127, .08);
  --shadow-lg: 0 10px 34px rgba(2, 47, 127, .14);

  --container: 1200px;
  --header-h: 76px;

  --ease: cubic-bezier(.4, 0, .2, 1);
}

/* ---------------------------------------------------------------------
   2. RESET
   --------------------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 16px);
}

body {
  margin: 0;
  font-family: var(--font-sans);
  font-size: var(--fs-base);
  line-height: 1.65;
  color: var(--ink-soft);
  background: var(--surface);
  -webkit-font-smoothing: antialiased;
}

img, svg, video { max-width: 100%; height: auto; display: block; }

a { color: var(--brand-blue); text-decoration: none; transition: color .18s var(--ease); }
a:hover { color: var(--brand-red); }

ul, ol { margin: 0; padding: 0; }
li { list-style: none; }

button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; background: none; border: 0; }

table { border-collapse: collapse; width: 100%; }

h1, h2, h3, h4, h5, h6 {
  margin: 0 0 var(--sp-3);
  font-family: var(--font-head);
  font-weight: 700;
  line-height: 1.15;
  color: var(--ink);
  letter-spacing: -0.01em;
}

h1 { font-size: var(--fs-4xl); }
h2 { font-size: var(--fs-3xl); }
h3 { font-size: var(--fs-2xl); }
h4 { font-size: var(--fs-xl); }

p { margin: 0 0 var(--sp-4); }
p:last-child { margin-bottom: 0; }

:focus-visible {
  outline: 3px solid var(--brand-yellow);
  outline-offset: 2px;
}

::selection { background: var(--brand-yellow); color: var(--ink); }

/* ---------------------------------------------------------------------
   3. LAYOUT
   --------------------------------------------------------------------- */
.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--sp-4);
}

.container--narrow { max-width: 840px; }

.section { padding-block: var(--sp-8); }
.section--tight { padding-block: var(--sp-7); }
.section--alt { background: var(--surface-alt); }
.section--blue {
  background: var(--brand-blue);
  color: rgba(255, 255, 255, .86);
}
.section--blue h1, .section--blue h2,
.section--blue h3, .section--blue h4 { color: #fff; }

.grid { display: grid; gap: var(--sp-5); }
.grid--2 { grid-template-columns: repeat(2, 1fr); }
.grid--3 { grid-template-columns: repeat(3, 1fr); }
.grid--4 { grid-template-columns: repeat(4, 1fr); }
.grid--sidebar { grid-template-columns: 280px 1fr; gap: var(--sp-6); }

.stack > * + * { margin-top: var(--sp-4); }
.flex { display: flex; gap: var(--sp-3); }
.flex--between { justify-content: space-between; align-items: center; }
.flex--center { justify-content: center; align-items: center; }
.flex--wrap { flex-wrap: wrap; }

/* ---------------------------------------------------------------------
   4. MOTIF KOTAK (diambil dari elemen grafis logo)
   --------------------------------------------------------------------- */
.checker {
  display: inline-flex;
  gap: 3px;
  transform: skewX(-18deg);
}
.checker i {
  width: 14px;
  height: 14px;
  display: block;
}
.checker i:nth-child(1) { background: var(--brand-red); }
.checker i:nth-child(2) { background: var(--brand-yellow); }
.checker i:nth-child(3) { background: var(--brand-blue); }

/* Garis aksen tiga warna */
.accent-bar {
  display: flex;
  height: 4px;
  width: 72px;
  overflow: hidden;
  border-radius: 2px;
}
.accent-bar span { flex: 1; }
.accent-bar span:nth-child(1) { background: var(--brand-red); }
.accent-bar span:nth-child(2) { background: var(--brand-yellow); }
.accent-bar span:nth-child(3) { background: var(--brand-blue); }
.section--blue .accent-bar span:nth-child(3) { background: #fff; }

/* ---------------------------------------------------------------------
   5. JUDUL SECTION
   --------------------------------------------------------------------- */
.section-head { margin-bottom: var(--sp-6); }
.section-head--center { text-align: center; }
.section-head--center .accent-bar { margin-inline: auto; }

.section-head .eyebrow {
  display: inline-block;
  font-family: var(--font-head);
  font-size: var(--fs-sm);
  font-weight: 600;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--brand-red);
  margin-bottom: var(--sp-2);
}
.section--blue .section-head .eyebrow { color: var(--brand-yellow); }

.section-head h2 { margin-bottom: var(--sp-3); }
.section-head .lead {
  max-width: 62ch;
  font-size: var(--fs-lg);
  color: var(--ink-muted);
}
.section--blue .section-head .lead { color: rgba(255, 255, 255, .78); }
.section-head--center .lead { margin-inline: auto; }

/* ---------------------------------------------------------------------
   6. TOMBOL
   --------------------------------------------------------------------- */
.btn {
  --btn-bg: var(--brand-blue);
  --btn-fg: #fff;
  --btn-bd: var(--brand-blue);

  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--sp-2);
  padding: 0.75rem 1.5rem;
  background: var(--btn-bg);
  color: var(--btn-fg);
  border: 2px solid var(--btn-bd);
  border-radius: var(--radius);
  font-family: var(--font-head);
  font-size: var(--fs-base);
  font-weight: 600;
  letter-spacing: .03em;
  text-transform: uppercase;
  line-height: 1.2;
  transition: transform .15s var(--ease), box-shadow .18s var(--ease),
              background-color .18s var(--ease), color .18s var(--ease);
}
.btn:hover { color: var(--btn-fg); transform: translateY(-1px); box-shadow: var(--shadow); }
.btn:active { transform: translateY(0); }

/* Merah = aksi utama (CTA) */
.btn--primary {
  --btn-bg: var(--brand-red);
  --btn-bd: var(--brand-red);
}
.btn--primary:hover { --btn-bg: var(--brand-red-700); --btn-bd: var(--brand-red-700); }

.btn--blue:hover { --btn-bg: var(--brand-blue-700); --btn-bd: var(--brand-blue-700); }

.btn--yellow {
  --btn-bg: var(--brand-yellow);
  --btn-fg: var(--ink);
  --btn-bd: var(--brand-yellow);
}
.btn--yellow:hover { --btn-bg: var(--brand-yellow-600); --btn-bd: var(--brand-yellow-600); color: var(--ink); }

.btn--outline {
  --btn-bg: transparent;
  --btn-fg: var(--brand-blue);
  --btn-bd: var(--brand-blue);
}
.btn--outline:hover { --btn-bg: var(--brand-blue); --btn-fg: #fff; }

.btn--ghost-light {
  --btn-bg: transparent;
  --btn-fg: #fff;
  --btn-bd: rgba(255, 255, 255, .5);
}
.btn--ghost-light:hover { --btn-bg: #fff; --btn-fg: var(--brand-blue); --btn-bd: #fff; }

.btn--sm { padding: 0.5rem 1rem; font-size: var(--fs-sm); }
.btn--lg { padding: 0.95rem 2rem; font-size: var(--fs-lg); }
.btn--block { width: 100%; }

.btn[disabled], .btn.is-disabled { opacity: .5; pointer-events: none; }

/* ---------------------------------------------------------------------
   7. KARTU
   --------------------------------------------------------------------- */
.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: border-color .2s var(--ease), box-shadow .2s var(--ease), transform .2s var(--ease);
}
.card:hover { border-color: var(--brand-blue-300); box-shadow: var(--shadow-lg); transform: translateY(-3px); }

.card__media {
  position: relative;
  aspect-ratio: 4 / 3;
  background: var(--surface-alt);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.card__media img { width: 100%; height: 100%; object-fit: contain; padding: var(--sp-4); }

.card__body { padding: var(--sp-4) var(--sp-5) var(--sp-5); }

.card__brand {
  font-size: var(--fs-xs);
  font-weight: 600;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--brand-red);
  margin-bottom: var(--sp-1);
}
.card__title {
  font-family: var(--font-head);
  font-size: var(--fs-xl);
  font-weight: 700;
  color: var(--ink);
  margin-bottom: var(--sp-2);
  line-height: 1.2;
}
.card__meta {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-2);
  margin-bottom: var(--sp-3);
}
.card__excerpt {
  font-size: var(--fs-sm);
  color: var(--ink-muted);
  margin-bottom: var(--sp-4);
}
.card__actions { display: flex; gap: var(--sp-2); }

/* Kartu kategori / industri */
.tile {
  position: relative;
  display: block;
  padding: var(--sp-5);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  border-top: 4px solid var(--brand-blue);
  transition: all .2s var(--ease);
}
.tile:hover {
  border-top-color: var(--brand-red);
  box-shadow: var(--shadow-lg);
  transform: translateY(-3px);
}
.tile__icon {
  width: 48px; height: 48px;
  margin-bottom: var(--sp-3);
  color: var(--brand-blue);
}
.tile__title {
  font-family: var(--font-head);
  font-size: var(--fs-lg);
  font-weight: 700;
  color: var(--ink);
  margin-bottom: var(--sp-1);
}
.tile__text { font-size: var(--fs-sm); color: var(--ink-muted); margin: 0; }

/* ---------------------------------------------------------------------
   8. BADGE & CHIP
   --------------------------------------------------------------------- */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 9px;
  border-radius: 999px;
  font-size: var(--fs-xs);
  font-weight: 600;
  line-height: 1.6;
  background: var(--brand-blue-100);
  color: var(--brand-blue);
}
.badge--red    { background: var(--brand-red-100);    color: var(--brand-red-700); }
.badge--yellow { background: var(--brand-yellow-100); color: #7a5f00; }
.badge--muted  { background: var(--line-soft);        color: var(--ink-muted); }

.chip {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
  padding: 6px 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  font-size: var(--fs-sm);
  color: var(--ink-soft);
  transition: all .18s var(--ease);
}
.chip:hover { border-color: var(--brand-blue); color: var(--brand-blue); }
.chip.is-active {
  background: var(--brand-blue);
  border-color: var(--brand-blue);
  color: #fff;
}

/* ---------------------------------------------------------------------
   9. FORM
   --------------------------------------------------------------------- */
.field { margin-bottom: var(--sp-4); }

.label {
  display: block;
  margin-bottom: var(--sp-2);
  font-size: var(--fs-sm);
  font-weight: 600;
  color: var(--ink);
}
.label .req { color: var(--brand-red); }
.label .opt { font-weight: 400; color: var(--ink-muted); }

.input, .select, .textarea {
  width: 100%;
  padding: 0.7rem 0.9rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  font-size: var(--fs-base);
  color: var(--ink);
  transition: border-color .18s var(--ease), box-shadow .18s var(--ease);
}
.input:focus, .select:focus, .textarea:focus {
  outline: none;
  border-color: var(--brand-blue);
  box-shadow: 0 0 0 3px rgba(2, 47, 127, .12);
}
.input::placeholder, .textarea::placeholder { color: #a3abb8; }

.textarea { min-height: 130px; resize: vertical; }

.select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%236b7482' d='M1 1l5 5 5-5'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0.9rem center;
  padding-right: 2.4rem;
}

.field--error .input,
.field--error .select,
.field--error .textarea { border-color: var(--brand-red); }

.field__error {
  margin-top: var(--sp-1);
  font-size: var(--fs-sm);
  color: var(--brand-red);
}
.field__hint {
  margin-top: var(--sp-1);
  font-size: var(--fs-sm);
  color: var(--ink-muted);
}

.check { display: flex; align-items: flex-start; gap: var(--sp-2); font-size: var(--fs-sm); }
.check input { margin-top: 4px; accent-color: var(--brand-blue); }

/* ---------------------------------------------------------------------
   10. ALERT
   --------------------------------------------------------------------- */
.alert {
  display: flex;
  gap: var(--sp-3);
  padding: var(--sp-4);
  border-radius: var(--radius);
  border-left: 4px solid var(--brand-blue);
  background: var(--brand-blue-100);
  font-size: var(--fs-sm);
  margin-bottom: var(--sp-4);
}
.alert--success { border-color: var(--success); background: #e8f6ee; color: #0a6137; }
.alert--error   { border-color: var(--brand-red); background: var(--brand-red-100); color: #8a1016; }
.alert--warning { border-color: var(--brand-yellow); background: var(--brand-yellow-100); color: #7a5f00; }

/* ---------------------------------------------------------------------
   11. TABEL SPESIFIKASI
   --------------------------------------------------------------------- */
.spec-table { font-size: var(--fs-sm); }
.spec-table th, .spec-table td {
  padding: 0.7rem 0.9rem;
  border-bottom: 1px solid var(--line-soft);
  text-align: left;
  vertical-align: top;
}
.spec-table th {
  width: 40%;
  font-weight: 600;
  color: var(--ink);
  background: var(--surface-alt);
}
.spec-table tr:last-child th,
.spec-table tr:last-child td { border-bottom: 0; }

/* ---------------------------------------------------------------------
   12. BREADCRUMB
   --------------------------------------------------------------------- */
.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--sp-2);
  font-size: var(--fs-sm);
  color: var(--ink-muted);
}
.breadcrumb a { color: inherit; }
.breadcrumb a:hover { color: var(--brand-red); }
.breadcrumb li + li::before { content: '/'; margin-right: var(--sp-2); opacity: .5; }
.breadcrumb li { display: flex; align-items: center; }
.breadcrumb .is-current { color: var(--ink); font-weight: 500; }

/* ---------------------------------------------------------------------
   13. PAGE BANNER
   --------------------------------------------------------------------- */
.page-banner {
  position: relative;
  padding-block: var(--sp-7);
  background: var(--brand-blue);
  color: #fff;
  overflow: hidden;
}
.page-banner::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(100deg, var(--brand-blue-900) 0%, var(--brand-blue) 55%, transparent 100%);
  opacity: .9;
}
.page-banner > * { position: relative; z-index: 1; }
.page-banner h1 { color: #fff; margin-bottom: var(--sp-2); }
.page-banner .breadcrumb { color: rgba(255, 255, 255, .72); }
.page-banner .breadcrumb .is-current { color: var(--brand-yellow); }

/* ---------------------------------------------------------------------
   14. PAGINASI
   --------------------------------------------------------------------- */
.pagination {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-2);
  justify-content: center;
  margin-top: var(--sp-6);
}
.pagination a, .pagination span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 42px;
  height: 42px;
  padding-inline: var(--sp-3);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  font-size: var(--fs-sm);
  font-weight: 600;
  color: var(--ink-soft);
}
.pagination a:hover { border-color: var(--brand-blue); color: var(--brand-blue); }
.pagination .is-current {
  background: var(--brand-blue);
  border-color: var(--brand-blue);
  color: #fff;
}
.pagination .is-disabled { opacity: .4; pointer-events: none; }

/* ---------------------------------------------------------------------
   15. UTILITAS
   --------------------------------------------------------------------- */
.text-center { text-align: center; }
.text-right  { text-align: right; }
.text-muted  { color: var(--ink-muted); }
.text-red    { color: var(--brand-red); }
.text-blue   { color: var(--brand-blue); }
.text-sm     { font-size: var(--fs-sm); }
.text-lg     { font-size: var(--fs-lg); }
.uppercase   { text-transform: uppercase; letter-spacing: .06em; }
.fw-600      { font-weight: 600; }

.mt-0 { margin-top: 0; }    .mb-0 { margin-bottom: 0; }
.mt-3 { margin-top: var(--sp-3); } .mb-3 { margin-bottom: var(--sp-3); }
.mt-4 { margin-top: var(--sp-4); } .mb-4 { margin-bottom: var(--sp-4); }
.mt-5 { margin-top: var(--sp-5); } .mb-5 { margin-bottom: var(--sp-5); }
.mt-6 { margin-top: var(--sp-6); } .mb-6 { margin-bottom: var(--sp-6); }

.sr-only {
  position: absolute; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}

.skip-link {
  position: absolute;
  left: var(--sp-4);
  top: -100px;
  z-index: 999;
  padding: var(--sp-3) var(--sp-4);
  background: var(--brand-yellow);
  color: var(--ink);
  font-weight: 600;
  border-radius: var(--radius);
  transition: top .2s var(--ease);
}
.skip-link:focus { top: var(--sp-4); color: var(--ink); }

.empty-state {
  padding: var(--sp-8) var(--sp-4);
  text-align: center;
  color: var(--ink-muted);
}

/* ---------------------------------------------------------------------
   16. RESPONSIF
   --------------------------------------------------------------------- */
@media (max-width: 1024px) {
  :root { --fs-4xl: 2.5rem; --fs-3xl: 2rem; }
  .grid--4 { grid-template-columns: repeat(3, 1fr); }
  .grid--sidebar { grid-template-columns: 240px 1fr; }
}

@media (max-width: 860px) {
  :root { --fs-4xl: 2.1rem; --fs-3xl: 1.75rem; --fs-2xl: 1.5rem; }
  .section { padding-block: var(--sp-7); }
  .grid--3, .grid--4 { grid-template-columns: repeat(2, 1fr); }
  .grid--sidebar { grid-template-columns: 1fr; }
}

@media (max-width: 560px) {
  :root { --fs-4xl: 1.85rem; --fs-3xl: 1.55rem; }
  .container { padding-inline: var(--sp-4); }
  .grid--2, .grid--3, .grid--4 { grid-template-columns: 1fr; }
  .btn { width: 100%; }
  .card__actions { flex-direction: column; }
}

/* ---------------------------------------------------------------------
   17. CETAK
   --------------------------------------------------------------------- */
@media print {
  .site-header, .site-footer, .btn, .float-actions, .skip-link { display: none !important; }
  body { color: #000; font-size: 11pt; }
  .page-banner { background: none; color: #000; padding-block: 0; }
  .page-banner h1 { color: #000; }
  a[href]::after { content: ' (' attr(href) ')'; font-size: 9pt; color: #555; }
}

/* ---------------------------------------------------------------------
   18. PREFERENSI GERAK
   --------------------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .01ms !important;
    transition-duration: .01ms !important;
  }
}
