/* ==========================================================================
   TSS Theme — Shared Design System
   /assets/tss-theme.css
   
   Single source of truth for the Twelve Stone Studio dark theme.
   All customer-facing pages link to this file and use its tokens.
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=League+Spartan:wght@400;500;600;700&display=swap');

/* -------------------------------------------------------------------------- */
/* DESIGN TOKENS                                                              */
/* -------------------------------------------------------------------------- */

:root {
  /* Brand */
  --tss-primary: #15DFE4;       /* Bright Teal */
  --tss-primary-dark: #0FB9B1;  /* Teal hover */
  --tss-secondary: #FF5702;     /* Orange accent */
  --tss-orange: #FF5702;        /* Site orange color */

  /* Surfaces */
  --tss-bg: #000000;            /* True black (OLED) */
  --tss-surface: #1C1C1E;       /* Card backgrounds */
  --tss-surface-elevated: #2C2C2E; /* Elevated cards, dropdowns */
  --tss-surface-glass: rgba(28, 28, 30, 0.85);

  /* Text */
  --tss-text: #FFFFFF;
  --tss-text-dim: #8E8E93;
  --tss-text-inverse: #000000;

  /* Feedback */
  --tss-success: #34C759;
  --tss-danger: #FF3B30;
  --tss-warning: #FF9500;

  /* Borders */
  --tss-border: rgba(255, 255, 255, 0.08);
  --tss-border-subtle: rgba(255, 255, 255, 0.05);

  /* Radii */
  --tss-radius-sm: 8px;
  --tss-radius-md: 16px;
  --tss-radius-lg: 24px;
  --tss-radius-pill: 999px;

  /* Spacing */
  --tss-space-xs: 4px;
  --tss-space-sm: 8px;
  --tss-space-md: 16px;
  --tss-space-lg: 24px;
  --tss-space-xl: 32px;

  /* Motion */
  --tss-ease-fast: 0.2s cubic-bezier(0.25, 1, 0.5, 1);
  --tss-ease-smooth: 0.4s cubic-bezier(0.2, 0.8, 0.2, 1);
}

/* -------------------------------------------------------------------------- */
/* RESET                                                                      */
/* -------------------------------------------------------------------------- */

*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; padding: 0; -webkit-tap-highlight-color: transparent; }

body {
  font-family: 'League Spartan', system-ui, -apple-system, sans-serif;
  background-color: var(--tss-bg);
  color: var(--tss-text);
  line-height: 1.5;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

img, video { max-width: 100%; height: auto; display: block; }
a { color: var(--tss-primary); text-decoration: none; }
a:hover { text-decoration: underline; }

/* -------------------------------------------------------------------------- */
/* COMMON INPUTS                                                              */
/* -------------------------------------------------------------------------- */

.tss-input,
.tss-select {
  width: 100%;
  padding: 12px var(--tss-space-md);
  font-family: inherit;
  font-size: 15px;
  color: var(--tss-text);
  background: var(--tss-surface);
  border: 1px solid var(--tss-border);
  border-radius: var(--tss-radius-sm);
  transition: border-color var(--tss-ease-fast);
  outline: none;
}

.tss-input:focus,
.tss-select:focus {
  border-color: var(--tss-primary);
  box-shadow: 0 0 0 2px rgba(21, 223, 228, 0.15);
}

.tss-input::placeholder { color: var(--tss-text-dim); }

/* -------------------------------------------------------------------------- */
/* COMMON BUTTONS                                                             */
/* -------------------------------------------------------------------------- */

.tss-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: inherit;
  font-weight: 700;
  font-size: 15px;
  min-height: 44px;
  padding: 10px 20px;
  border-radius: var(--tss-radius-sm);
  border: none;
  cursor: pointer;
  transition: all var(--tss-ease-fast);
}

.tss-btn-primary {
  background: var(--tss-primary);
  color: var(--tss-text-inverse);
}
.tss-btn-primary:hover { background: var(--tss-primary-dark); }
.tss-btn-primary:active { transform: scale(0.97); }

.tss-btn-secondary {
  background: var(--tss-surface-elevated);
  color: var(--tss-text);
  border: 1px solid var(--tss-border);
}
.tss-btn-secondary:hover { background: rgba(255, 255, 255, 0.12); }

.tss-btn-danger {
  background: transparent;
  color: var(--tss-danger);
  border: 1px solid var(--tss-danger);
}
.tss-btn-danger:hover { background: rgba(255, 59, 48, 0.1); }

.tss-btn-ghost {
  background: transparent;
  color: var(--tss-text);
}
.tss-btn-ghost:hover { background: rgba(255, 255, 255, 0.08); }

/* Pill-shaped (floating cart, tags, etc.) */
.tss-btn-pill {
  border-radius: var(--tss-radius-pill);
}

/* -------------------------------------------------------------------------- */
/* CARDS                                                                      */
/* -------------------------------------------------------------------------- */

.tss-card {
  background: var(--tss-surface);
  border: 1px solid var(--tss-border-subtle);
  border-radius: var(--tss-radius-md);
  padding: var(--tss-space-md);
}

.tss-card-elevated {
  background: var(--tss-surface-elevated);
}

/* -------------------------------------------------------------------------- */
/* LABELS & BADGES                                                            */
/* -------------------------------------------------------------------------- */

.tss-label {
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--tss-text-dim);
}

.tss-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 8px;
  border-radius: var(--tss-radius-pill);
  font-size: 11px;
  font-weight: 600;
  background: var(--tss-surface-elevated);
  color: var(--tss-text);
  border: 1px solid var(--tss-border);
}

.tss-badge-primary {
  background: rgba(21, 223, 228, 0.15);
  color: var(--tss-primary);
  border-color: rgba(21, 223, 228, 0.3);
}

.tss-badge-secondary {
  background: rgba(255, 87, 2, 0.15);
  color: var(--tss-secondary);
  border-color: rgba(255, 87, 2, 0.3);
}

/* -------------------------------------------------------------------------- */
/* MINI CART (Floating)                                                       */
/* -------------------------------------------------------------------------- */

.tss-float-cart-btn {
  position: fixed;
  bottom: var(--tss-space-md);
  right: var(--tss-space-md);
  padding: 12px 16px;
  font-size: 15px;
  font-weight: 900;
  font-family: inherit;
  border-radius: var(--tss-radius-pill);
  border: 1px solid var(--tss-border);
  background: var(--tss-surface);
  color: var(--tss-text);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
  cursor: pointer;
  z-index: 200;
  transition: transform var(--tss-ease-fast);
}
.tss-float-cart-btn:hover { transform: scale(1.05); }

.tss-mini-cart {
  position: fixed;
  right: var(--tss-space-md);
  bottom: 64px;
  width: min(420px, calc(100vw - 28px));
  max-height: 55vh;
  overflow: auto;
  display: none;
  padding: var(--tss-space-md);
  border-radius: var(--tss-radius-md);
  border: 1px solid var(--tss-border);
  background: var(--tss-surface);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.5);
  z-index: 200;
}

.tss-mini-cart-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: var(--tss-space-sm);
  font-weight: 900;
  font-size: 15px;
}

/* -------------------------------------------------------------------------- */
/* TOAST                                                                      */
/* -------------------------------------------------------------------------- */

.tss-toast {
  position: fixed;
  top: 50%;
  left: 50%;
  right: auto;
  bottom: auto;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  color: var(--tss-orange);
  padding: 16px 24px;
  border-radius: var(--tss-radius-md);
  border: 1px solid rgba(255,255,255,0.1);
  opacity: 0;
  transform: translate(-50%, -50%) scale(0.95);
  transition: opacity 0.3s cubic-bezier(0.2, 0.8, 0.2, 1), transform 0.3s cubic-bezier(0.2, 0.8, 0.2, 1);
  z-index: 9999;
  text-align: center;
  pointer-events: none;
  font-weight: 600;
  font-size: 16px;
  max-width: 85vw;
  box-shadow: 0 10px 40px rgba(0,0,0,0.5);
}
.tss-toast.show { opacity: 1; transform: translate(-50%, -50%) scale(1); }

/* -------------------------------------------------------------------------- */
/* STATUS INDICATORS                                                          */
/* -------------------------------------------------------------------------- */

.tss-status {
  padding: var(--tss-space-md);
  border-radius: var(--tss-radius-sm);
  margin: var(--tss-space-md) 0;
}

.tss-status-info {
  background: rgba(21, 223, 228, 0.08);
  border-left: 4px solid var(--tss-primary);
  color: var(--tss-text);
}

.tss-status-error {
  background: rgba(255, 59, 48, 0.08);
  border-left: 4px solid var(--tss-danger);
}

.tss-status-success {
  background: rgba(52, 199, 89, 0.08);
  border-left: 4px solid var(--tss-success);
}

/* -------------------------------------------------------------------------- */
/* SPINNER                                                                    */
/* -------------------------------------------------------------------------- */

.tss-spinner {
  display: inline-block;
  width: 24px;
  height: 24px;
  border: 3px solid var(--tss-surface-elevated);
  border-top-color: var(--tss-primary);
  border-radius: 50%;
  animation: tss-spin 0.7s linear infinite;
}

.tss-spinner-lg { width: 40px; height: 40px; }

@keyframes tss-spin { to { transform: rotate(360deg); } }

/* -------------------------------------------------------------------------- */
/* TRUST HEADER                                                               */
/* -------------------------------------------------------------------------- */

.tss-header {
  border-bottom: 1px solid var(--tss-border);
  padding: var(--tss-space-sm) var(--tss-space-md);
}

.tss-header-inner {
  max-width: 1100px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}

.tss-header-logo {
  height: 42px;
  border-radius: var(--tss-radius-sm);
}

.tss-trust-badge {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  font-weight: 700;
  color: var(--tss-text-dim);
}

/* -------------------------------------------------------------------------- */
/* CONTAINER                                                                  */
/* -------------------------------------------------------------------------- */

.tss-wrap {
  max-width: 1100px;
  margin: 0 auto;
  padding: var(--tss-space-md);
}

/* -------------------------------------------------------------------------- */
/* UTILITIES                                                                  */
/* -------------------------------------------------------------------------- */

@media (max-width: 600px) {
  .desktop-only { display: none !important; }
}

@media (min-width: 601px) {
  .mobile-only { display: none !important; }
}

/* -------------------------------------------------------------------------- */
/* RESPONSIVE HELPERS                                                         */
/* -------------------------------------------------------------------------- */

@media (max-width: 640px) {
  .tss-header-logo { height: 36px; }
  .tss-trust-badge { font-size: 0; }
  .tss-trust-badge img { height: 20px !important; width: 20px !important; }
}
