/* Identicomm Market - Atelier refresh
   Design goals:
   - Editorial clarity, minimal noise, strong hierarchy
   - Brand-led: navy + merlot accents on warm paper
   - Accessible focus states, motion-safe, fast
*/

:root{
  /* Warm paper base */
  --idm-bg: #fbfaf7;
  --idm-card: rgba(255,255,255,0.86);
  --idm-text: #0b1220;
  --idm-muted: rgba(11,18,32,0.70);
  --idm-border: rgba(11,18,32,0.12);

  /* Brand accents (keep existing vars too) */
  --idm-navy: #0b1b3a;
  --idm-navy-2: #08152d;
  --idm-red: #8b1e2d;
  --idm-red-2: #a52536;

  /* Rings and shadows */
  --idm-ring: rgba(139,30,45,0.28);
  --idm-shadow: 0 18px 60px rgba(2,6,23,0.10);
  --idm-shadow-soft: 0 14px 34px rgba(2,6,23,0.08);

  --idm-radius: 16px;
  --idm-radius-sm: 12px;
  --idm-container: 1180px;
}

/* Subtle paper wash background */
body{
  background: var(--idm-bg);
  color: var(--idm-text);
}
body::before{
  content:"";
  position: fixed;
  inset: 0;
  pointer-events:none;
  z-index:-1;
  background:
    radial-gradient(900px 520px at 10% 16%, rgba(139,30,45,0.14), transparent 60%),
    radial-gradient(820px 520px at 92% 20%, rgba(11,27,58,0.12), transparent 62%),
    radial-gradient(760px 520px at 86% 88%, rgba(139,30,45,0.08), transparent 62%);
  filter: blur(18px);
  opacity: 0.95;
}
body::after{
  content:"";
  position: fixed;
  inset: 0;
  pointer-events:none;
  z-index:-1;
  background-image: radial-gradient(rgba(11,18,32,0.10) 1px, transparent 1px);
  background-size: 30px 30px;
  opacity: 0.05;
  mix-blend-mode: multiply;
}

/* Clear hierarchy */
h1,h2,h3{ letter-spacing: -0.02em; }
p,li{ color: var(--idm-muted); }

/* Links */
a{ text-underline-offset: 3px; }
a:hover{ text-decoration-thickness: 2px; }

/* Focus states (keyboard) */
:where(a,button,input,select,textarea,[tabindex]):focus-visible{
  outline: 3px solid var(--idm-ring);
  outline-offset: 3px;
  border-radius: 10px;
}

/* Header: glassy paper, restrained */
.idm-header{
  background: rgba(251,250,247,0.78);
  color: var(--idm-text);
  border-bottom: 1px solid rgba(11,18,32,0.10);
  box-shadow: 0 10px 40px rgba(2,6,23,0.06);
  backdrop-filter: blur(14px);
}
.idm-topbar{
  background: transparent;
  border-bottom: 0;
}
.idm-kicker{ color: rgba(11,18,32,0.70); font-weight: 700; }
.idm-toplink{ color: rgba(11,18,32,0.72); }
.idm-toplink svg{ opacity: 0.75; }

.idm-nav a{
  color: rgba(11,18,32,0.86);
}
.idm-nav a:hover{
  color: var(--idm-red);
}

/* Search: clean input */
.idm-search{
  background: rgba(255,255,255,0.80);
  border: 1px solid rgba(11,18,32,0.12);
  box-shadow: 0 12px 26px rgba(2,6,23,0.06);
}
.idm-search__input{
  color: var(--idm-text);
}
.idm-search__input::placeholder{
  color: rgba(11,18,32,0.45);
}
.idm-search__btn{
  background: var(--idm-navy);
}
.idm-search__btn:hover{
  background: var(--idm-navy-2);
}

/* Buttons: premium, firm */
.idm-btn{
  border-radius: 999px;
  padding: 12px 16px;
  border: 1px solid rgba(11,18,32,0.14);
  background: rgba(255,255,255,0.86);
  color: var(--idm-text);
  box-shadow: 0 10px 24px rgba(2,6,23,0.06);
  transition: transform 160ms ease, box-shadow 160ms ease, background 160ms ease, border-color 160ms ease;
}
.idm-btn:hover{
  transform: translateY(-1px);
  box-shadow: 0 16px 38px rgba(2,6,23,0.10);
}
.idm-btn--primary{
  background: var(--idm-red);
  border-color: rgba(0,0,0,0);
  color: #fff;
  box-shadow: 0 18px 44px rgba(139,30,45,0.22);
}
.idm-btn--primary:hover{
  background: var(--idm-red-2);
}
.idm-btn--ghost{
  background: rgba(255,255,255,0.70);
}
.idm-btn--dark{
  background: var(--idm-navy);
  color: #fff;
  border-color: rgba(0,0,0,0);
}

/* Cards and sections */
.idm-card,
.idm-panel,
.idm-feature,
.woocommerce ul.products li.product,
.idm-footer__card{
  background: var(--idm-card);
  border: 1px solid rgba(11,18,32,0.10);
  border-radius: var(--idm-radius);
  box-shadow: var(--idm-shadow-soft);
}
.idm-card:hover,
.woocommerce ul.products li.product:hover{
  box-shadow: var(--idm-shadow);
  transform: translateY(-2px);
}
.woocommerce ul.products li.product{
  transition: transform 180ms ease, box-shadow 180ms ease;
}

/* Hero: tighter, more editorial */
.idm-hero{
  padding-top: 44px;
}
.idm-hero__inner{
  gap: 26px;
}
.idm-hero h1{
  font-size: clamp(2.1rem, 4.2vw, 3.2rem);
  line-height: 1.05;
}
.idm-hero p{
  font-size: 1.05rem;
  line-height: 1.65;
  max-width: 62ch;
}

/* Fix: ensure hero kicker/subtitle remain readable on dark hero background */
.idm-hero__kicker,
.idm-hero__subtitle{
  color: rgba(255,255,255,0.92) !important;
}

/* Footer: force all footer text and links to white */
.idm-footer,
.idm-footer a,
.idm-footer p,
.idm-footer span,
.idm-footer li,
.idm-footer h1,
.idm-footer h2,
.idm-footer h3,
.idm-footer h4,
.idm-footer h5,
.idm-footer h6{
  color: #ffffff !important;
}
.idm-footer a:hover{
  opacity: 0.92;
}

/* Woo: product buttons */
.woocommerce a.button,
.woocommerce button.button,
.woocommerce input.button{
  border-radius: 999px !important;
  padding: 10px 14px !important;
  background: var(--idm-red) !important;
  color: #fff !important;
  border: 0 !important;
}
.woocommerce a.button:hover,
.woocommerce button.button:hover,
.woocommerce input.button:hover{
  background: var(--idm-red-2) !important;
}

/* Mobile: hide header cart icon; keep cart in menu */
@media (max-width: 720px){
  .idm-cart{ display:none !important; }
  .idm-topbar__right{ display:none; } /* reduce clutter */
}

/* Motion safety */
@media (prefers-reduced-motion: reduce){
  *{ scroll-behavior:auto !important; }
  .idm-btn, .idm-card, .woocommerce ul.products li.product{
    transition: none !important;
  }
}


/* Header icon buttons on light header */
.idm-mnav-btn{
  color: var(--idm-text);
  border: 1px solid rgba(11,18,32,0.14);
  background: rgba(255,255,255,0.70);
}
.idm-mnav-btn:hover{
  background: rgba(255,255,255,0.90);
}
.idm-cart{
  color: var(--idm-text);
  background: rgba(255,255,255,0.70);
  border: 1px solid rgba(11,18,32,0.14);
}
.idm-cart:hover{
  background: rgba(255,255,255,0.90);
}
.idm-cart__count{
  background: var(--idm-red);
  color: #fff;
}

/* === Contrast fixes (hero + footer) === */
/* Force hero kicker/subtitle to readable white even if CSS order/minify changes */
.idm-hero{ color: #fff !important; }
.idm-hero__kicker,
.idm-hero__subtitle{
  color: rgba(255,255,255,0.92) !important;
}
.idm-hero__subtitle a{ color: #fff !important; text-decoration-color: rgba(255,255,255,0.55); }
.idm-hero__subtitle a:hover{ text-decoration-color: rgba(255,255,255,0.85); }

/* Footer: make all footer text white (including menu links) */
.idm-footer,
.idm-footer *{
  color: rgba(255,255,255,0.92) !important;
}
.idm-footer a{ text-decoration-color: rgba(255,255,255,0.45) !important; }
.idm-footer a:hover{ text-decoration-color: rgba(255,255,255,0.85) !important; opacity: 0.96; }
