@import url('https://fonts.googleapis.com/css?family=Raleway:400,600,700');

:root {
  --brand: #ffcc00;
  --brand-text: #111111;
  --dark: #343537;
  --link: #00ace9;
  --logo: #6e6e6e;
  --bg: #ffffff;
  --card-bg: #ffffff;
  --border: #e9e9e9;
  --text: #8a8a8a;
  --text-p: #777777;
  --heading: #333333;
  --danger: #b42318;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  font-family: 'Raleway', "Trebuchet MS", Arial, Helvetica, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  overflow-x: hidden;
}

a { color: var(--link); }
a:hover { text-decoration: none; }

/* Header: white bar with logo + hamburger, matches the old site's templatemo_top */
.site-header, .admin-header {
  background: #ffffff;
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 100;
}

.header-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 16px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  color: var(--dark);
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 10px;
}
.logo-icon {
  height: 30px;
  width: auto;
  display: block;
  fill: var(--logo);
  flex-shrink: 0;
}
.logo-text {
  font-weight: 700;
  font-size: 1.25rem;
  letter-spacing: .3px;
  color: var(--dark);
  white-space: nowrap;
}
.logo-text em { font-weight: 400; font-style: normal; color: var(--text); }
.admin-tag {
  font-size: .8rem;
  text-transform: uppercase;
  color: var(--text);
  font-weight: 400;
  letter-spacing: .5px;
}

/* Hero slideshow, matches the old design's fading full-width slider */
.slideshow-container {
  position: relative;
  width: 100%;
  aspect-ratio: 1920 / 700;
  overflow: hidden;
  border-radius: 4px;
  margin-bottom: 30px;
  background: var(--dark);
}
.slideshow-container .slide {
  display: none;
  position: absolute;
  inset: 0;
  animation: fadeSlide 10s ease-out;
}
.slideshow-container .slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
/* Slow "Ken Burns" zoom while a slide is shown, matching the old site's effect */
@keyframes fadeSlide {
  from { opacity: .9; transform: scale(1.1); }
  to { opacity: 1; transform: scale(1.15); }
}

/* Hamburger button, matches .openbtn from the old design */
.openbtn {
  font-size: 1rem;
  cursor: pointer;
  background-color: var(--brand);
  color: var(--brand-text);
  padding: 10px 16px;
  border: none;
  border-radius: 3px;
  text-transform: uppercase;
  font-weight: 600;
  letter-spacing: .5px;
}
.openbtn:hover { background-color: #e6b800; }

/* Slide-in sidebar nav, matches the old design's yellow full-height sidebar */
.sidebar {
  height: 100%;
  width: 0;
  max-width: 85vw;
  position: fixed;
  z-index: 1000;
  top: 0;
  right: 0;
  background-color: var(--brand);
  overflow-x: hidden;
  overflow-y: auto;
  transition: 0.3s;
  padding-top: 60px;
}
.sidebar a {
  padding: 10px 8px 10px 32px;
  text-decoration: none;
  font-size: 1.3rem;
  color: var(--brand-text);
  display: block;
  text-transform: uppercase;
  font-weight: 600;
  letter-spacing: .5px;
  transition: 0.2s;
}
.sidebar a:hover { color: #fff; }
.sidebar a.sidebar-small {
  font-size: .8rem;
  text-transform: none;
  font-weight: 400;
  opacity: .8;
}
.sidebar .closebtn {
  position: absolute;
  top: 6px;
  right: 25px;
  font-size: 2.2rem;
  color: var(--brand-text);
}

.site-main {
  max-width: 1200px;
  margin: 0 auto;
  padding: 40px 20px 70px;
  min-height: 60vh;
}

.site-footer {
  text-align: center;
  padding: 24px;
  color: var(--text);
  font-size: .85rem;
  border-top: 1px solid var(--border);
}
.site-footer p { color: var(--text); margin: 4px 0; }
.site-footer a { color: var(--text); }
.site-footer a:hover { color: var(--link); text-decoration: underline; }

.contact-box {
  background: #f5f5f5;
  border-radius: 4px;
  padding: 28px;
  max-width: 420px;
}
.contact-box p { margin: 0 0 14px; color: var(--text-p); }
.contact-box a { color: var(--link); }

.legal-content {
  background: #f5f5f5;
  border-radius: 4px;
  padding: 30px;
  max-width: 800px;
  font-size: .85rem;
  color: var(--text-p);
  line-height: 1.7;
}
.legal-content p { color: var(--text-p); margin: 0 0 4px; }

h1 {
  font-size: 1.5em;
  font-weight: 400;
  color: #ffffff;
  background: var(--dark);
  padding: 10px 16px;
  display: inline-block;
  margin: 0 0 24px;
}
h2 { font-size: 24px; color: var(--heading); font-weight: 400; }
p { color: var(--text-p); }

.db-select {
  margin-bottom: 24px;
  display: flex;
  align-items: center;
  gap: 10px;
}
.db-select label {
  font-size: .8rem;
  text-transform: uppercase;
  letter-spacing: .3px;
  color: var(--text);
}
.db-select select {
  padding: 8px 12px;
  border: 1px solid var(--border);
  border-radius: 3px;
  font-size: .95rem;
  font-family: inherit;
  color: var(--heading);
  background: #fff;
}
.db-active-badge {
  font-size: .78rem;
  color: var(--text);
  background: #f0f7ee;
  border: 1px solid #cfe8c5;
  border-radius: 3px;
  padding: 5px 10px;
}
.db-active-badge strong { color: #1e7e34; }

.category-filter {
  margin-bottom: 24px;
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}
.category-filter a {
  padding: 7px 16px;
  border-radius: 3px;
  background: #f5f5f5;
  border: 1px solid var(--border);
  color: var(--heading);
  text-decoration: none;
  font-size: .85rem;
  text-transform: uppercase;
  letter-spacing: .3px;
}
.category-filter a.active {
  background: var(--brand);
  color: var(--brand-text);
  border-color: var(--brand);
}

.category-filter-mobile { display: none; }
.category-filter-mobile select {
  width: 100%;
  padding: 16px 18px;
  border-radius: 4px;
  border: 1px solid var(--border);
  background: #f5f5f5;
  color: var(--heading);
  font-size: 1.15rem;
}
.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;
}

/* Product portfolio grid, matches the old .portfolio-item / .overlay-p hover pattern */
.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 24px;
}

.product-card {
  position: relative;
  display: block;
  text-decoration: none;
  color: var(--heading);
  overflow: hidden;
  border-radius: 4px;
  background: #f5f5f5;
}

.product-image, .product-detail-image {
  aspect-ratio: 4 / 3;
  background: #f0f0f0;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}
.product-image img, .product-detail-image img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}
.product-image-placeholder { color: var(--text); font-size: .85rem; }

.product-card .overlay-p {
  position: absolute;
  inset: 0;
  background-color: rgba(255, 204, 0, 0.92);
  opacity: 0;
  transition: opacity 0.2s ease-in-out;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 10px;
}
.product-card:hover .overlay-p { opacity: 1; }
.product-card .overlay-p .product-name {
  color: #111;
  font-weight: 700;
  text-transform: uppercase;
  font-size: .95rem;
  margin-bottom: 6px;
}
.product-card .overlay-p .product-price { color: #111; font-weight: 600; }

.product-detail {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
}
@media (max-width: 700px) {
  .product-detail { grid-template-columns: 1fr; }
}
.product-category {
  text-transform: uppercase;
  font-size: .8rem;
  letter-spacing: .5px;
  color: var(--link);
  margin-bottom: 4px;
}
.product-price { color: var(--heading); font-weight: 700; font-size: 1.2rem; }

.product-detail-info form {
  margin-top: 24px;
  display: flex;
  align-items: flex-end;
  gap: 12px;
  flex-wrap: wrap;
}
.product-detail-info label { display: flex; flex-direction: column; font-size: .8rem; color: var(--text); text-transform: uppercase; }
.product-detail-info input[type="number"] { width: 80px; padding: 8px; border: 1px solid var(--border); border-radius: 3px; margin-top: 4px; }

button, .button {
  background: var(--brand);
  color: var(--brand-text);
  border: none;
  padding: 11px 22px;
  border-radius: 3px;
  cursor: pointer;
  font-size: .9rem;
  text-decoration: none;
  display: inline-block;
  text-transform: uppercase;
  font-weight: 600;
  letter-spacing: .3px;
}
button:hover, .button:hover { background: #e6b800; }

table, .cart-table {
  display: block;
  width: 100%;
  max-width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  border-collapse: collapse;
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 4px;
}
table > thead, table > tbody, .cart-table > thead, .cart-table > tbody { display: table; width: 100%; }
table th, table td,
.cart-table th, .cart-table td {
  padding: 12px;
  border-bottom: 1px solid var(--border);
  text-align: left;
  font-size: .92rem;
  color: var(--text-p);
}
table th, .cart-table th {
  background: var(--dark);
  color: #fff;
  font-weight: 400;
  text-transform: uppercase;
  font-size: .78rem;
  letter-spacing: .4px;
}

.cart-total { font-size: 1.1rem; margin: 18px 0; color: var(--heading); }

.inline-form { display: inline-block; margin: 0; }
.inline-form input[type="number"] { width: 60px; padding: 4px; }
.inline-form button { padding: 6px 12px; font-size: .8rem; background: var(--danger); color: #fff; }
.inline-form button:hover { background: #8f1c13; }

.account-form, .checkout-form {
  display: flex;
  flex-direction: column;
  gap: 14px;
  max-width: 480px;
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 28px;
}
.account-form label, .checkout-form label {
  display: flex;
  flex-direction: column;
  font-size: .78rem;
  color: var(--text);
  text-transform: uppercase;
  letter-spacing: .3px;
  gap: 5px;
}
.account-form label.checkbox { flex-direction: row; align-items: center; gap: 8px; text-transform: none; }
.account-form input, .account-form select, .account-form textarea,
.checkout-form input, .checkout-form select, .checkout-form textarea {
  padding: 10px;
  border: 1px solid var(--border);
  border-radius: 3px;
  font-size: .95rem;
  font-family: inherit;
  color: var(--heading);
}

.error {
  background: #fdecea;
  color: var(--danger);
  padding: 10px 14px;
  border-radius: 3px;
  font-size: .9rem;
}
.success {
  background: #eaf7ea;
  color: #1e7e34;
  padding: 10px 14px;
  border-radius: 3px;
  font-size: .9rem;
}

.dashboard-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 16px;
}
.dashboard-card {
  background: #f5f5f5;
  border-radius: 4px;
  padding: 24px;
  text-align: center;
}
.dashboard-card strong { display: block; font-size: 2rem; color: var(--dark); }
.dashboard-card span { color: var(--text); font-size: .85rem; text-transform: uppercase; letter-spacing: .3px; }

.thumb { width: 48px; height: 48px; object-fit: cover; border-radius: 3px; }

/* Mobile optimization */
@media (max-width: 600px) {
  .header-inner { padding: 12px 16px; }
  .logo-text { font-size: 1.05rem; }
  .logo-icon { height: 24px; }
  .openbtn { padding: 8px 12px; font-size: .9rem; }
  .admin-tag { display: none; }

  .site-main { padding: 24px 16px 50px; }

  h1 { font-size: 1.2em; padding: 8px 12px; margin-bottom: 18px; }

  .slideshow-container { border-radius: 0; margin: 0 -16px 24px; width: calc(100% + 32px); }

  .product-grid { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 14px; }

  .category-filter { display: none; }
  .category-filter-mobile { display: block; margin-bottom: 18px; }

  .account-form, .checkout-form, .contact-box, .legal-content { padding: 18px; }

  .sidebar a { font-size: 1.1rem; padding: 9px 8px 9px 24px; }

  table th, table td, .cart-table th, .cart-table td { padding: 9px; font-size: .85rem; }
}
