/*
Theme Name: 3D Printing Ballarat
Theme URI: https://3dprintingballarat.com
Author: Derek Robertson & ChatGPT
Author URI: https://derek.net.au
Description: Lean WooCommerce-integrated theme for instant 3D print quoting and checkout (STL/OBJ upload → price → pay).
Version: 1.0.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: 3dpb
*/

/* Light theme base tokens */
:root {
    --bg: #f5f5f8;           /* page background */
    --card: #ffffff;         /* cards / panels */
    --txt: #111827;          /* main text */
    --txt-light: #ffffff;    /* main text reversed */
    --muted: #6b7280;        /* muted text */
    --accent: #0ea5e9;       /* primary accent (light blue/teal) */

    --border-subtle: #e5e7eb;
    --input-bg: #ffffff;
    --input-border: #d1d5db;

    --shadow-soft: 0 10px 30px rgba(15, 23, 42, 0.12);
    --shadow-subtle: 0 3px 10px rgba(15, 23, 42, 0.08);
}

body {
    margin: 0;
    background: radial-gradient(circle at top, #ffffff 0, #f5f5f8 40%, #eef2ff 100%);
    color: var(--txt);
    font: 16px/1.5 system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial;
}

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

a:hover {
    text-decoration: underline;
}

.container {
    max-width: 1080px;
    margin: 0 auto;
    padding: 24px;
}

/* Cards */
.card {
    background: var(--card);
    border-radius: 16px;
    padding: 24px;
    box-shadow: var(--shadow-soft);
    border: 1px solid rgba(148, 163, 184, 0.15);
}

.fullwidth {
  margin-left: -1000px;
  margin-right: -1000px;
  padding: 24px 1000px;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 10px 16px;
    border-radius: 999px;
    background: linear-gradient(135deg, #0ea5e9, #22c55e);
    color: #ffffff;
    font-weight: 700;
    border: 0;
    cursor: pointer;
    box-shadow: 0 8px 20px rgba(14, 165, 233, 0.4);
    transition: transform 0.1s ease, box-shadow 0.1s ease, filter 0.1s ease;
}
.btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 10px 26px rgba(14, 165, 233, 0.45);
    filter: brightness(1.05);
}
.btn:active {
    transform: translateY(0);
    box-shadow: 0 4px 14px rgba(15, 23, 42, 0.25);
}
.btn:disabled {
    opacity: .6;
    cursor: not-allowed;
    box-shadow: var(--shadow-subtle);
}

/* Simple grid */
.grid {
    display: grid;
    gap: 16px;
}

/* Forms */
label {
    display: block;
    margin: 10px 0 6px;
    font-weight: 600;
    color: #0f172a;
}

input,
select {
    width: calc( 100% - 20px );
    padding: 10px;
    border-radius: 10px;
    border: 1px solid var(--input-border);
    background: var(--input-bg);
    color: var(--txt);
    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
    transition: border-color 0.12s ease, box-shadow 0.12s ease, background-color 0.12s ease;
}

input[type=file] {
    padding: 8px;
    background: var(--input-bg);
}

input:focus,
select:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(14, 165, 233, 0.2);
    background: #f9fafb;
}

textarea {
    outline: none;
    width: calc( 100% - 20px );
    padding: 10px;
    border-radius: 10px;
    box-shadow: 0 0 0 3px rgba(14, 165, 233, 0.2);
    background: #f9fafb;
    border-color: var(--accent);
}

/* Notices */
.notice {
    padding: 12px 14px;
    border-radius: 10px;
    background: linear-gradient(120deg, #ecfdf5, #e0f2fe);
    color: #064e3b;
    border: 1px solid #a7f3d0;
    box-shadow: var(--shadow-subtle);
}

small.help {
    display: block;
    color: var(--muted);
    margin-top: 4px;
}

/* Layout chrome */
.header {
    padding: 24px 0;
    border-bottom: 1px solid var(--border-subtle);
    margin-bottom: 18px;
}
.footer {
    padding: 32px 0;
    border-top: 1px solid var(--border-subtle);
    margin-top: 24px;
    color: var(--muted);
    font-size: 14px;
}

/* Headings */
h1, h2, h3 {
    line-height: 1.2;
    margin: 0 0 12px;
    letter-spacing: -0.02em;
}
h1 {
    font-size: 2.2rem;
}
h2 {
    font-size: 1.6rem;
}
h3 {
    font-size: 1.25rem;
}

/* ----------------------------
   Feature sections (hero / category blocks)
   Usage: <section class="section-feature section-feature--blue">...</section>
----------------------------- */

.section-feature {
    position: relative;
    border-radius: 24px;
    padding: 28px 24px;
    box-shadow: var(--shadow-soft);
    overflow: hidden;
    border: 1px solid rgba(148, 163, 184, 0.16);
}

/* subtle glossy highlight */
.section-feature::before {
    content: "";
    position: absolute;
    inset: -40%;
    background: radial-gradient(circle at 0% 0%, rgba(255, 255, 255, 0.65), transparent 55%);
    mix-blend-mode: soft-light;
    pointer-events: none;
}

/* Neutral/light grey feature (default) */
.section-feature--neutral {
    background: radial-gradient(circle at top left, #ffffff 0, #f9fafb 40%, #e5e7eb 100%);
    color: #111827;
}

/* Cool blue / cyan combo (good for “FDM” / “Prototypes & Parts”) */
.section-feature--blue {
    background: radial-gradient(circle at top left, #e0f2fe 0, #eff6ff 40%, #e0f7fa 100%);
    color: #0f172a;
}
.section-feature--blue h2,
.section-feature--blue h3 {
    color: #075985;
}

/* Teal / green combo (good for “Resin” / “Miniatures & Models”) */
.section-feature--teal {
    background: radial-gradient(circle at top right, #ccfbf1 0, #e0f2fe 45%, #f0fdfa 100%);
    color: #022c22;
}
.section-feature--teal h2,
.section-feature--teal h3 {
    color: #0f766e;
}

/* Warm orange / magenta combo (good for “Hobby & Cosplay”, “TPU”) */
.section-feature--warm {
    background: radial-gradient(circle at top left, #fef3c7 0, #fee2e2 35%, #fae8ff 100%);
    color: #111827;
}
.section-feature--warm h2,
.section-feature--warm h3 {
    color: #b45309;
}

/* Dark-on-light accent for inline badges or small labels */
.badge-accent {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 10px;
    border-radius: 999px;
    background: rgba(14, 165, 233, 0.09);
    color: #0369a1;
    font-size: 12px;
    font-weight: 600;
}

/* ----------------------------
   WooCommerce Cart/Checkout tweaks
----------------------------- */

.woocommerce-cart .card,
.woocommerce-checkout .card {
    background: var(--card);
    border-radius: 16px;
    box-shadow: var(--shadow-soft);
    border: 1px solid rgba(148, 163, 184, 0.18);
}

.woocommerce table.shop_table {
    background: #ffffff;
    color: var(--txt);
    border-radius: 16px;
    border: 1px solid var(--border-subtle);
    box-shadow: var(--shadow-subtle);
}

.woocommerce a.button,
.woocommerce button.button,
.woocommerce input.button {
    background: linear-gradient(135deg, #0ea5e9, #22c55e);
    color: #ffffff;
    border-radius: 999px;
    border: none;
    padding: 0.6em 1.4em;
    font-weight: 600;
    box-shadow: 0 6px 18px rgba(14, 165, 233, 0.35);
    transition: transform 0.1s ease, box-shadow 0.1s ease, filter 0.1s ease;
}
.woocommerce a.button:hover,
.woocommerce button.button:hover,
.woocommerce input.button:hover {
    transform: translateY(-1px);
    box-shadow: 0 8px 22px rgba(14, 165, 233, 0.45);
    filter: brightness(1.05);
}

/* ===== Header layout ===== */

.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgba(255,255,255,0.94);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(15,23,42,0.06);
  box-shadow: 0 6px 18px rgba(15,23,42,0.08);
}

body.dark .site-header {
  background: rgba(15,17,21,0.9);
  border-bottom-color: rgba(148,163,184,0.2);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.25rem;
  padding-top: 0.65rem;
  padding-bottom: 0.65rem;
}

/* ===== Branding ===== */

.site-branding .brand-link {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  text-decoration: none;
}

.brand-logo img {
  max-height: 46px;
  width: auto;
}

.brand-mark {
  width: 40px;
  height: 40px;
  border-radius: 1rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1rem;
  color: #fff;
  background: radial-gradient(circle at 10% 0, #22c55e, #0ea5e9);
  box-shadow: 0 6px 14px rgba(15,23,42,0.3);
}

.brand-text {
  display: flex;
  flex-direction: column;
}

.brand-title {
  font-weight: 700;
  letter-spacing: 0.03em;
  font-size: 1rem;
  text-transform: uppercase;
  color: #0f172a;
}

.brand-tagline {
  font-size: 0.78rem;
  color: #64748b;
}

body.dark .brand-title { color: #e2e8f0; }
body.dark .brand-tagline { color: #94a3b8; }

/* ===== Nav + actions ===== */

.header-right {
  display: flex;
  align-items: center;
  gap: 1.25rem;
}

.primary-nav {
  display: flex;
}

.primary-nav .menu {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  list-style: none;
  padding: 0;
  margin: 0;
}

.primary-nav a {
  font-size: 0.9rem;
  text-decoration: none;
  color: #0f172a;
  padding: 0.35rem 0;
  position: relative;
}

body.dark .primary-nav a { color: #e2e8f0; }

.primary-nav a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 0;
  height: 2px;
  background: linear-gradient(90deg, #0ea5e9, #22c55e);
  transition: width 0.18s ease-out;
}

.primary-nav a:hover::after,
.primary-nav .current-menu-item > a::after {
  width: 100%;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.btn.header-cta {
  padding: 0.5rem 1.1rem;
  font-size: 0.88rem;
  border-radius: 999px;
  box-shadow: 0 8px 20px rgba(56,189,248,0.35);
  white-space: nowrap;
}

/* Cart icon */

.header-cart {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 999px;
  border: 1px solid rgba(148,163,184,0.6);
  text-decoration: none;
}

.header-cart .cart-icon {
  width: 16px;
  height: 16px;
  border: 2px solid #0f172a;
  border-radius: 3px;
  box-sizing: border-box;
  position: relative;
}

.header-cart .cart-icon::before {
  content: "";
  position: absolute;
  top: -4px;
  left: 3px;
  right: 3px;
  height: 3px;
  border-radius: 3px 3px 0 0;
  border: 2px solid #0f172a;
  border-bottom: none;
}

.header-cart .cart-count {
  position: absolute;
  top: -4px;
  right: -4px;
  min-width: 16px;
  height: 16px;
  border-radius: 999px;
  background: #ef4444;
  color: #fff;
  font-size: 0.65rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* ===== Mobile nav ===== */

.nav-toggle {
  display: none;
  width: 40px;
  height: 40px;
  border-radius: 999px;
  border: 1px solid rgba(148,163,184,0.6);
  background: transparent;
  padding: 0;
  margin-left: auto;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 4px;
}

.nav-toggle-bar {
  width: 18px;
  height: 2px;
  border-radius: 999px;
  background: #0f172a;
}

body.dark .nav-toggle-bar { background: #e2e8f0; }

@media (max-width: 900px) {
  .header-inner {
    padding-top: 0.55rem;
    padding-bottom: 0.55rem;
  }

  .nav-toggle {
    display: inline-flex;
  }

  .header-right {
    position: absolute;
    inset-inline: 0;
    top: 100%;
    margin-top: 4px;
    padding-inline: 1rem;
    padding-bottom: 0.6rem;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.75rem;
    background: rgba(255,255,255,0.98);
    box-shadow: 0 16px 26px rgba(15,23,42,0.15);
    transform-origin: top;
    transform: scaleY(0);
    opacity: 0;
    pointer-events: none;
    transition: transform 0.18s ease-out, opacity 0.18s ease-out;
  }

  body.dark .header-right {
    background: rgba(15,17,21,0.98);
  }

  .site-header.is-open .header-right {
    transform: scaleY(1);
    opacity: 1;
    pointer-events: auto;
  }

  .primary-nav .menu {
    flex-direction: column;
    align-items: flex-start;
  }

  .header-actions {
    width: 100%;
    justify-content: flex-start;
  }
}
/* ============================================================
   RESPONSIVE ENHANCEMENTS — 3D PRINTING BALLARAT THEME
   Mobile-first clean scaling for forms, grids, header, cards
   Add AFTER all existing CSS
   ============================================================ */

/* ---- Tablets and small laptops ---- */
@media (max-width: 1024px) {

  .container {
    padding: 20px;
  }

  h1 { font-size: 2rem; }
  h2 { font-size: 1.45rem; }
  h3 { font-size: 1.2rem; }

  .card {
    padding: 20px;
    border-radius: 14px;
  }
}

/* ---- General mobile (up to 768px) ---- */
@media (max-width: 768px) {

  .container {
    padding: 18px;
  }

  .grid {
    grid-template-columns: 1fr !important;
    gap: 14px;
  }

  input,
  select,
  textarea {
    width: calc(100% - 18px);
    font-size: 15px;
  }

  label {
    font-size: 0.95rem;
  }

  .btn {
    width: 100%;
    text-align: center;
    padding: 12px 18px;
    font-size: 1rem;
  }

  .notice {
    padding: 12px;
    font-size: 0.95rem;
  }

  .header {
    padding: 18px 0;
  }

  .header-inner {
    gap: 1rem;
  }

  .site-branding img {
    max-height: 40px;
  }
}

/* ---- Mobile (phones under 600px) ---- */
@media (max-width: 600px) {

  .container {
    padding: 16px;
  }

  h1 { font-size: 1.7rem; }
  h2 { font-size: 1.35rem; }
  h3 { font-size: 1.15rem; }

  .card {
    padding: 18px;
  }

  .section-feature {
    padding: 22px 18px;
    border-radius: 18px;
  }

  .badge-accent {
    font-size: 11px;
    padding: 3px 8px;
  }

  .header-actions .btn {
    width: 100%;
  }

  .brand-title {
    font-size: 0.95rem;
  }

  .brand-tagline {
    font-size: 0.75rem;
  }

  .header-cart {
    width: 32px;
    height: 32px;
  }

  .header-cart .cart-icon {
    width: 14px;
    height: 14px;
  }
}

/* ---- Small mobile (under 480px) ---- */
@media (max-width: 480px) {

  .container {
    padding: 14px;
  }

  body {
    font-size: 15px;
  }

  h1 { font-size: 1.55rem; }
  h2 { font-size: 1.25rem; }

  input,
  select,
  textarea {
    font-size: 14px;
    padding: 9px;
  }

  .btn {
    padding: 12px;
    font-size: 0.95rem;
  }

  .site-header {
    padding-left: 10px;
    padding-right: 10px;
  }

  .brand-logo img {
    max-height: 34px;
  }

  .brand-mark {
    width: 34px;
    height: 34px;
    font-size: 0.85rem;
  }
}

/* ---- Ultra-small devices (under 360px) ---- */
@media (max-width: 360px) {

  .container {
    padding: 12px;
  }

  h1 { font-size: 1.4rem; }
  h2 { font-size: 1.2rem; }

  input,
  select,
  textarea {
    width: calc(100% - 16px);
    padding: 8px;
    font-size: 13px;
  }

  .btn {
    font-size: 0.88rem;
    padding: 10px;
  }

  .header-inner {
    flex-direction: row;
    justify-content: space-between;
  }

  .brand-mark {
    width: 30px;
    height: 30px;
  }
}
/* ===========================
   WooCommerce Shop Layout
   =========================== */

.shop-container {
    padding-top: 24px;
    padding-bottom: 32px;
}

.shop-header {
    margin-bottom: 18px;
}

.shop-title {
    margin: 0 0 6px;
}

/* Card wrapping the product grid */
.shop-card {
    margin-top: 8px;
}

/* Product grid (fully responsive) */
.shop-grid {
    display: grid;
    gap: 20px;
    grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
}

/* Product card */
.product-card {
    background: var(--card);
    border-radius: 16px;
    padding: 14px 14px 16px;
    box-shadow: var(--shadow-soft);
    border: 1px solid rgba(148, 163, 184, 0.16);
    display: flex;
    flex-direction: column;
}

/* Thumbnail */
.product-thumb-wrap {
    border-radius: 12px;
    overflow: hidden;
    background: #e5e7eb;
    margin-bottom: 10px;
}

.product-thumb-wrap img {
    display: block;
    width: 100%;
    height: auto;
}

/* Title */
.product-card .woocommerce-loop-product__title {
    font-size: 1rem;
    margin: 0 0 6px;
}

/* Price row */
.product-meta-row {
    margin-bottom: 10px;
}

.product-card .price {
    font-weight: 600;
}

/* Add to cart */
.product-actions {
    margin-top: auto;
}

.product-actions .button {
    width: 100%;
    text-align: center;
    border-radius: 999px;
    padding: 0.55rem 1rem;
}

/* Match your gradient button style */
.product-actions .button,
.woocommerce ul.products li.product .button {
    background: linear-gradient(135deg, #0ea5e9, #22c55e);
    color: #ffffff;
    border: none;
    font-weight: 600;
    box-shadow: 0 6px 18px rgba(14, 165, 233, 0.35);
    transition: transform 0.1s ease, box-shadow 0.1s ease, filter 0.1s ease;
}

.product-actions .button:hover,
.woocommerce ul.products li.product .button:hover {
    transform: translateY(-1px);
    box-shadow: 0 8px 22px rgba(14, 165, 233, 0.45);
    filter: brightness(1.05);
}

/* Result count / ordering row */
.woocommerce-result-count,
.woocommerce-ordering {
    font-size: 0.9rem;
}

.woocommerce-result-count {
    color: var(--muted);
}
