/* ==========================================================================
   ETCO Specialty Products, Inc.
   Brand palette carried over from the original site:
     purple #4b1177 (links / logo mark), charcoal #4D4D4D (nav), #E6E6E6 (nav text)
   ========================================================================== */

:root {
  --etco-purple:        #4b1177;
  --etco-purple-dark:   #350b55;
  --etco-purple-darker: #24073a;
  --etco-purple-light:  #6d2ba8;
  --etco-purple-pale:   #f3eef8;
  --etco-charcoal:      #4d4d4d;
  --etco-charcoal-dark: #333333;
  --etco-gray:          #e6e6e6;
  --etco-ink:           #222222;
  --etco-muted:         #6b6b73;
  --etco-line:          #e3e1e8;

  --bs-primary: var(--etco-purple);
  --bs-link-color: var(--etco-purple);
  --bs-link-hover-color: var(--etco-purple-light);

  --etco-shadow-sm: 0 1px 2px rgba(36, 7, 58, .06), 0 2px 8px rgba(36, 7, 58, .05);
  --etco-shadow-md: 0 2px 6px rgba(36, 7, 58, .07), 0 12px 28px rgba(36, 7, 58, .09);
  --etco-radius: .625rem;
}

/* ---------- base ---------------------------------------------------------- */

body {
  font-family: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  color: var(--etco-ink);
  background: #fff;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5, h6, .display-1, .display-2, .display-3,
.navbar-nav .nav-link, .btn, .stat-value {
  font-family: "Oswald", "Inter", system-ui, sans-serif;
  font-weight: 500;
  letter-spacing: .01em;
}

h1, h2, h3 { color: var(--etco-ink); }

a { color: var(--etco-purple); text-decoration-thickness: 1px; text-underline-offset: 2px; }
a:hover { color: var(--etco-purple-light); }

.text-purple { color: var(--etco-purple) !important; }
.bg-purple   { background-color: var(--etco-purple) !important; }
.bg-purple-pale { background-color: var(--etco-purple-pale) !important; }
.bg-charcoal { background-color: var(--etco-charcoal) !important; }

/* Accent rule used above section headings */
.rule-accent {
  width: 3rem; height: 4px; border: 0; opacity: 1;
  background: var(--etco-purple); border-radius: 2px; margin: 0 0 1.25rem;
}
.rule-accent.mx-auto { margin-left: auto; margin-right: auto; }

.section { padding: 4.5rem 0; }
.section-sm { padding: 3rem 0; }

.eyebrow {
  font-family: "Oswald", sans-serif;
  text-transform: uppercase;
  letter-spacing: .16em;
  font-size: .8125rem;
  color: var(--etco-purple);
  font-weight: 500;
}

/* ---------- buttons ------------------------------------------------------- */

.btn { border-radius: .375rem; letter-spacing: .04em; text-transform: uppercase; font-size: .875rem; }
.btn-lg { font-size: .95rem; padding: .75rem 1.75rem; }

.btn-etco {
  background: var(--etco-purple); border: 1px solid var(--etco-purple); color: #fff;
}
.btn-etco:hover, .btn-etco:focus {
  background: var(--etco-purple-light); border-color: var(--etco-purple-light); color: #fff;
}
.btn-etco-outline {
  background: transparent; border: 1px solid var(--etco-purple); color: var(--etco-purple);
}
.btn-etco-outline:hover, .btn-etco-outline:focus {
  background: var(--etco-purple); color: #fff;
}
.btn-etco-light {
  background: rgba(255, 255, 255, .12); border: 1px solid rgba(255, 255, 255, .6); color: #fff;
  backdrop-filter: blur(2px);
}
.btn-etco-light:hover, .btn-etco-light:focus { background: #fff; color: var(--etco-purple); border-color: #fff; }

.btn:focus-visible, .form-control:focus, .form-select:focus, .page-link:focus {
  box-shadow: 0 0 0 .2rem rgba(75, 17, 119, .28);
  border-color: var(--etco-purple-light);
  outline: none;
}

/* ---------- header / nav -------------------------------------------------- */

.topbar {
  background: var(--etco-charcoal);
  color: var(--etco-gray);
  font-size: .8125rem;
  padding: .5rem 0;
}
.topbar a { color: var(--etco-gray); text-decoration: none; }
.topbar a:hover { color: #fff; }

.navbar-etco {
  background: #fff;
  box-shadow: 0 1px 0 var(--etco-line), 0 2px 14px rgba(36, 7, 58, .05);
  padding: .625rem 0;
}
.navbar-etco .navbar-brand img { height: 52px; width: auto; display: block; }
.navbar-etco .nav-link {
  color: var(--etco-charcoal);
  text-transform: uppercase;
  font-size: .875rem;
  letter-spacing: .05em;
  padding: .5rem .9rem;
  border-radius: .3rem;
}
.navbar-etco .nav-link:hover,
.navbar-etco .nav-link:focus { color: var(--etco-purple); background: var(--etco-purple-pale); }
.navbar-etco .nav-link.active { color: var(--etco-purple); font-weight: 600; }
.navbar-etco .nav-link.active::after {
  content: ""; display: block; height: 2px; background: var(--etco-purple);
  margin: .3rem .15rem -.15rem; border-radius: 2px;
}
.navbar-etco .dropdown-menu {
  border: 1px solid var(--etco-line); border-radius: var(--etco-radius);
  box-shadow: var(--etco-shadow-md); padding: .4rem;
}
.navbar-etco .dropdown-item {
  border-radius: .35rem; font-size: .9rem; padding: .5rem .75rem;
}
.navbar-etco .dropdown-item:hover,
.navbar-etco .dropdown-item:focus { background: var(--etco-purple-pale); color: var(--etco-purple); }
.navbar-toggler { border-color: var(--etco-line); }
.navbar-toggler:focus { box-shadow: 0 0 0 .2rem rgba(75, 17, 119, .2); }

/* ---------- hero ---------------------------------------------------------- */

.hero {
  position: relative;
  background: var(--etco-purple-darker) center/cover no-repeat;
  color: #fff;
  padding: 6rem 0;
}
.hero::before {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(100deg, rgba(36, 7, 58, .93) 0%, rgba(75, 17, 119, .84) 45%, rgba(75, 17, 119, .55) 100%);
}
.hero > .container { position: relative; z-index: 1; }
.hero h1 { color: #fff; font-size: clamp(2.1rem, 4.6vw, 3.4rem); line-height: 1.12; }
.hero .lead { color: rgba(255, 255, 255, .9); max-width: 40rem; }
.hero .eyebrow { color: #d9c4ee; }

.page-hero {
  background: linear-gradient(100deg, var(--etco-purple-darker), var(--etco-purple));
  color: #fff;
  padding: 3.5rem 0 3rem;
}
.page-hero h1 { color: #fff; font-size: clamp(1.9rem, 3.6vw, 2.75rem); margin: 0; }
.page-hero .lead { color: rgba(255, 255, 255, .88); margin-bottom: 0; }
.page-hero .breadcrumb { margin: 0 0 .75rem; --bs-breadcrumb-divider-color: rgba(255,255,255,.5); }
.page-hero .breadcrumb a { color: rgba(255, 255, 255, .82); text-decoration: none; }
.page-hero .breadcrumb a:hover { color: #fff; text-decoration: underline; }
.page-hero .breadcrumb-item.active { color: rgba(255, 255, 255, .65); }

/* ---------- cards --------------------------------------------------------- */

.card-etco {
  border: 1px solid var(--etco-line);
  border-radius: var(--etco-radius);
  background: #fff;
  box-shadow: var(--etco-shadow-sm);
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
  height: 100%;
}
.card-etco:hover { transform: translateY(-3px); box-shadow: var(--etco-shadow-md); border-color: #cfc6dd; }

.icon-badge {
  width: 3rem; height: 3rem; border-radius: .55rem;
  display: inline-flex; align-items: center; justify-content: center;
  background: var(--etco-purple-pale); color: var(--etco-purple); font-size: 1.25rem;
  flex: 0 0 auto;
}
.icon-badge-lg { width: 3.75rem; height: 3.75rem; font-size: 1.5rem; }
.icon-badge-solid { background: var(--etco-purple); color: #fff; }

/* stat strip */
.stat-strip { background: var(--etco-purple-pale); border-top: 1px solid var(--etco-line); border-bottom: 1px solid var(--etco-line); }
.stat-value { font-size: 2.25rem; color: var(--etco-purple); line-height: 1; font-weight: 600; }
.stat-label { font-size: .8125rem; text-transform: uppercase; letter-spacing: .1em; color: var(--etco-muted); }

/* ---------- catalog ------------------------------------------------------- */

.filter-bar {
  background: #fff; border: 1px solid var(--etco-line);
  border-radius: var(--etco-radius); box-shadow: var(--etco-shadow-sm); padding: 1.25rem;
}
.form-control, .form-select { border-color: #d7d3de; border-radius: .375rem; }

.product-card { display: flex; flex-direction: column; height: 100%; }
.product-card .product-body { padding: 1.25rem 1.25rem .75rem; flex: 1 1 auto; }
.product-card .product-foot {
  padding: .75rem 1.25rem 1.15rem; border-top: 1px solid var(--etco-line); margin-top: .5rem;
}
.product-card h3 { font-size: 1.0625rem; margin: 0 0 .35rem; line-height: 1.3; }
.product-card h3 a { color: var(--etco-ink); text-decoration: none; }
.product-card:hover h3 a { color: var(--etco-purple); }
.product-desc {
  font-size: .875rem; color: var(--etco-muted); margin: 0;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}

.chip {
  display: inline-block; font-size: .6875rem; text-transform: uppercase; letter-spacing: .07em;
  padding: .2rem .5rem; border-radius: 999px; background: var(--etco-purple-pale);
  color: var(--etco-purple); border: 1px solid #e0d5ee; white-space: nowrap;
}
.chip-app { background: #f1f1f4; color: var(--etco-charcoal); border-color: #e2e2e7; }
.chip-count { background: var(--etco-purple); color: #fff; border-color: var(--etco-purple); }

/* spec table */
.spec-wrap {
  border: 1px solid var(--etco-line); border-radius: var(--etco-radius);
  background: #fff; box-shadow: var(--etco-shadow-sm); overflow: hidden;
}
.spec-scroll { overflow-x: auto; }
.table-spec { margin: 0; font-size: .875rem; white-space: nowrap; }
.table-spec thead th {
  background: var(--etco-purple); color: #fff; font-family: "Oswald", sans-serif;
  font-weight: 400; text-transform: uppercase; font-size: .75rem; letter-spacing: .05em;
  border: 0; padding: .7rem .85rem; position: sticky; top: 0; vertical-align: middle;
}
.table-spec tbody td { padding: .6rem .85rem; border-color: var(--etco-line); vertical-align: middle; }
.table-spec tbody tr:nth-child(even) { background: #faf9fc; }
.table-spec tbody tr:hover { background: var(--etco-purple-pale); }
.table-spec td:first-child { font-weight: 600; color: var(--etco-purple); font-variant-numeric: tabular-nums; }

/* ---------- pagination ---------------------------------------------------- */

.pagination { --bs-pagination-color: var(--etco-charcoal); margin: 0; flex-wrap: wrap; gap: .25rem; }
.page-link {
  border: 1px solid var(--etco-line); border-radius: .375rem !important;
  min-width: 2.4rem; text-align: center; font-family: "Oswald", sans-serif; font-weight: 400;
}
.page-link:hover { background: var(--etco-purple-pale); color: var(--etco-purple); border-color: #ddd0ee; }
.page-item.active .page-link { background: var(--etco-purple); border-color: var(--etco-purple); color: #fff; }
.page-item.disabled .page-link { color: #b3b0ba; background: #fafafa; }

.page-status { font-size: .875rem; color: var(--etco-muted); }

/* ---------- misc content -------------------------------------------------- */

.prose p { line-height: 1.75; color: #35333c; }
.prose p:last-child { margin-bottom: 0; }

.timeline { position: relative; padding-left: 2.25rem; }
.timeline::before {
  content: ""; position: absolute; left: .6rem; top: .4rem; bottom: .4rem;
  width: 2px; background: linear-gradient(var(--etco-purple), #e0d5ee);
}
.timeline-item { position: relative; padding-bottom: 2rem; }
.timeline-item:last-child { padding-bottom: 0; }
.timeline-item::before {
  content: ""; position: absolute; left: -1.79rem; top: .45rem;
  width: .7rem; height: .7rem; border-radius: 50%;
  background: var(--etco-purple); box-shadow: 0 0 0 3px #fff, 0 0 0 5px #e0d5ee;
}
.timeline-year {
  font-family: "Oswald", sans-serif; color: var(--etco-purple);
  font-size: 1.05rem; letter-spacing: .04em; margin-bottom: .2rem;
}

.table-directory thead th {
  background: var(--etco-purple); color: #fff; font-family: "Oswald", sans-serif;
  font-weight: 400; text-transform: uppercase; font-size: .78rem; letter-spacing: .06em; border: 0;
}
.table-directory tbody td { vertical-align: middle; border-color: var(--etco-line); }

/* ---------- footer -------------------------------------------------------- */

.footer {
  background: var(--etco-charcoal-dark);
  color: #c9c7cd;
  padding: 3.5rem 0 0;
  font-size: .925rem;
}
.footer h5 {
  color: #fff; font-size: .95rem; text-transform: uppercase; letter-spacing: .1em; margin-bottom: 1.1rem;
}
.footer a { color: #c9c7cd; text-decoration: none; }
.footer a:hover { color: #fff; text-decoration: underline; }
.footer .list-unstyled li { margin-bottom: .5rem; }
.footer .fa-fw { color: var(--etco-purple-light); }
.footer-logo { height: 58px; width: auto; background: #fff; padding: .4rem .55rem; border-radius: .4rem; }
.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, .1); margin-top: 2.5rem; padding: 1.25rem 0;
  font-size: .8125rem; color: #9c99a3;
}
.footer-bottom a { color: #b7b4bd; }

.map-embed { border: 0; width: 100%; height: 320px; display: block; filter: grayscale(.25); }

/* ---------- utilities ----------------------------------------------------- */

.skip-link {
  position: absolute; left: -9999px; top: 0; z-index: 1200;
  background: var(--etco-purple); color: #fff; padding: .65rem 1rem; border-radius: 0 0 .4rem 0;
}
.skip-link:focus { left: 0; color: #fff; }

.back-to-top {
  position: fixed; right: 1.25rem; bottom: 1.25rem; z-index: 1030;
  width: 2.75rem; height: 2.75rem; border-radius: 50%;
  background: var(--etco-purple); color: #fff; border: 0;
  display: none; align-items: center; justify-content: center;
  box-shadow: var(--etco-shadow-md);
}
.back-to-top.show { display: flex; }
.back-to-top:hover { background: var(--etco-purple-light); color: #fff; }

@media (max-width: 991.98px) {
  .navbar-etco .nav-link.active::after { display: none; }
  .navbar-etco .navbar-nav { padding-top: .5rem; }
  .hero { padding: 4rem 0; }
  .section { padding: 3rem 0; }
}

@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
  .card-etco:hover { transform: none; }
}

@media print {
  .topbar, .navbar-etco, .footer, .filter-bar, .pagination, .back-to-top, .no-print { display: none !important; }
  .page-hero { background: none; color: #000; padding: 0 0 1rem; }
  .page-hero h1, .page-hero .lead { color: #000; }
  .table-spec { white-space: normal; font-size: .7rem; }
  .table-spec thead th { background: #eee !important; color: #000 !important; }
  .spec-wrap { box-shadow: none; }
  a[href]::after { content: ""; }
}
