/*
Theme Name: Two If By Tee
Theme URI: https://www.twoifbytee.com
Author: Jerimiah
Author URI: https://www.twoifbytee.com
Description: Custom lightweight theme for Two If By Tee — WooCommerce-ready, no page builder required. Includes a built-in split-scroll homepage section and the live Kalshi odds / shirt-sales poll widgets baked directly into the homepage template.
Version: 1.0
Requires at least: 5.9
Requires PHP: 7.4
Text Domain: tibt
*/

:root{
  --ink:#1a1a1a;
  --ink-soft:#4a4c55;
  --ink-muted:#888;
  --paper:#ffffff;
  --paper-2:#f6f7f9;
  --line:#e2e4e9;
  --dem:#1d4ed8;
  --dem-soft:#e7ecfb;
  --rep:#b91c1c;
  --ind:#7c3aed;
  --ind-soft:#f1e9fe;
  --rep-soft:#fbe9e7;
}

*, *::before, *::after{ box-sizing:border-box; }
html{ scroll-behavior:smooth; overflow-x:hidden; }
body{
  margin:0;
  overflow-x:hidden;
  font-family:-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,Helvetica,Arial,sans-serif;
  color:var(--ink);
  background:var(--paper);
  line-height:1.55;
}
img{ max-width:100%; height:auto; display:block; }
a{ color:var(--dem); text-decoration:none; }
a:hover{ text-decoration:underline; }
.screen-reader-text{
  position:absolute!important; clip:rect(1px,1px,1px,1px);
  width:1px; height:1px; overflow:hidden;
}

/* ---------- Header ---------- */
.site-header{
  border-bottom:1px solid var(--line);
  position:sticky; top:0; background:var(--paper); z-index:50;
}
.site-header-inner{
  max-width:1100px; margin:0 auto; padding:14px 24px;
  display:flex; align-items:center; justify-content:space-between; gap:20px;
}
.site-logo{
  font-size:19px; font-weight:800; color:var(--ink); letter-spacing:-0.01em;
}
.site-logo:hover{ text-decoration:none; }
.site-logo img{ max-height:40px; }
.site-nav ul{ list-style:none; display:flex; gap:22px; margin:0; padding:0; }
.site-nav a{ color:var(--ink-soft); font-size:14px; font-weight:600; }
.site-nav a:hover{ color:var(--ink); text-decoration:none; }
.cart-link{
  font-size:13px; font-weight:700; color:var(--ink);
  background:var(--paper-2); padding:8px 14px; border-radius:20px;
  white-space:nowrap;
}
.cart-link:hover{ background:var(--line); text-decoration:none; }

/* ---------- Generic page content ---------- */
.site-main{ max-width:900px; margin:0 auto; padding:48px 24px 80px; }
.site-main h1{ font-size:32px; font-weight:800; letter-spacing:-0.02em; margin:0 0 20px; }
.site-main .entry-meta{ font-size:13px; color:var(--ink-muted); margin-bottom:24px; }
.site-main .entry-content{ font-size:16px; color:#2a2a2a; }
.site-main .entry-content p{ margin:0 0 18px; }
.archive-list{ list-style:none; margin:0; padding:0; }
.archive-list li{ padding:20px 0; border-bottom:1px solid var(--line); }
.archive-list h2{ font-size:20px; margin:0 0 6px; }
.archive-list .entry-meta{ margin-bottom:8px; }

/* ---------- Widget areas ---------- */
.widget{ margin-bottom:28px; }
.widget-title{ font-size:14px; font-weight:700; text-transform:uppercase; letter-spacing:.04em; margin:0 0 12px; }
.site-sidebar{ max-width:320px; }
.footer-widgets{
  max-width:1100px; margin:0 auto; padding:40px 24px;
  display:grid; grid-template-columns:repeat(3,1fr); gap:32px;
}
@media (max-width:680px){ .footer-widgets{ grid-template-columns:1fr; } }

/* ---------- Footer ---------- */
.site-footer{ border-top:1px solid var(--line); margin-top:40px; }
.footer-bottom{
  max-width:1100px; margin:0 auto; padding:20px 24px 40px;
  display:flex; align-items:center; justify-content:space-between; flex-wrap:wrap; gap:12px;
  font-size:13px; color:var(--ink-muted);
}
.footer-bottom ul{ list-style:none; display:flex; gap:16px; margin:0; padding:0; }
.footer-bottom a{ color:var(--ink-muted); }

/* ---------- WooCommerce baseline ---------- */
.wc-wrap{ max-width:1240px; margin:0 auto; padding:32px 24px 80px; }
.woocommerce ul.products{
  display:grid !important;
  grid-template-columns:repeat(4,1fr) !important;
  gap:48px 28px; list-style:none; padding:0; margin:0 0 40px;
}
.woocommerce ul.products::before, .woocommerce ul.products::after{ content:none !important; display:none !important; }
@media (max-width:920px){ .woocommerce ul.products{ grid-template-columns:repeat(3,1fr) !important; } }
@media (max-width:680px){ .woocommerce ul.products{ grid-template-columns:repeat(2,1fr) !important; gap:36px 16px; } }
@media (max-width:420px){ .woocommerce ul.products{ grid-template-columns:1fr !important; } }
.woocommerce ul.products li.product{
  display:flex !important; flex-direction:column;
  width:auto !important; float:none !important; margin:0 !important;
  text-align:left; clear:none !important; position:relative;
}
.woocommerce ul.products li.product a.woocommerce-loop-product__link{
  display:block; background:var(--paper-2); border-radius:10px;
  padding:22px; margin-bottom:14px; text-decoration:none;
}
.woocommerce ul.products li.product a.add_to_cart_button{
  margin-top:auto; align-self:flex-start;
}
.woocommerce ul.products li.product img{
  width:100% !important; height:auto !important; max-width:100%;
  object-fit:contain; border-radius:4px; display:block; margin:0;
  box-shadow:0 14px 28px -16px rgba(0,0,0,.35);
}
.woocommerce ul.products li.product .woocommerce-loop-product__title{ font-size:14px; font-weight:600; color:var(--ink); margin:0 0 4px; }
.woocommerce ul.products li.product .price{ color:var(--ink); font-weight:800; font-size:14px; display:block; }
.woocommerce ul.products li.product a{ text-decoration:none; }
.woocommerce ul.products li.product .onsale{
  position:absolute; top:14px; left:14px; z-index:2; background:var(--ink); color:#fff;
  font-size:11px; font-weight:700; letter-spacing:.03em; text-transform:uppercase;
  padding:5px 10px; border-radius:4px; min-height:0; min-width:0; line-height:1.4;
}

/* Party-colored add-to-cart buttons */
.woocommerce a.button, .woocommerce button.button, .woocommerce input.button,
.woocommerce ul.products li.product a.add_to_cart_button{
  background:var(--ink); color:#fff; border-radius:24px; padding:11px 22px;
  border:none; font-weight:700; font-size:13px; letter-spacing:.02em; cursor:pointer;
  box-shadow:0 6px 16px -8px rgba(0,0,0,.4);
  transition:transform .12s ease, box-shadow .12s ease, background .12s ease;
}
.woocommerce a.button:hover, .woocommerce button.button:hover, .woocommerce ul.products li.product a.add_to_cart_button:hover{
  transform:translateY(-1px); box-shadow:0 10px 20px -8px rgba(0,0,0,.45); color:#fff; text-decoration:none;
}
.woocommerce ul.products li.product.product_cat-democrat a.add_to_cart_button{ background:var(--dem); }
.woocommerce ul.products li.product.product_cat-democrat a.add_to_cart_button:hover{ background:#1640b8; }
.woocommerce ul.products li.product.product_cat-republican a.add_to_cart_button{ background:var(--rep); }
.woocommerce ul.products li.product.product_cat-republican a.add_to_cart_button:hover{ background:#8f1616; }
.woocommerce ul.products li.product.product_cat-independent a.add_to_cart_button{ background:var(--ind); }
.woocommerce ul.products li.product.product_cat-independent a.add_to_cart_button:hover{ background:#6425c9; }

.woocommerce a.button, .woocommerce button.button, .woocommerce input.button{
  background:var(--ink); color:#fff; border-radius:8px; padding:10px 18px;
  border:none; font-weight:700; font-size:14px; cursor:pointer;
}
.woocommerce a.button:hover, .woocommerce button.button:hover{ background:#333; color:#fff; text-decoration:none; }

/* ================================================================
   Homepage: Hero
================================================================ */
.tibt-hero{ text-align:center; padding:64px 20px 48px; }
.tibt-hero h1{ font-size:clamp(30px,5vw,44px); font-weight:800; margin:0 0 12px; letter-spacing:-0.02em; }
.tibt-hero p{ font-size:17px; color:var(--ink-soft); max-width:540px; margin:0 auto; }

/* ================================================================
   Homepage: Split-scroll reveal
================================================================ */
#tibt-split-scroll{ position:relative; height:115vh; }
#tibt-split-scroll *{ box-sizing:border-box; }
.tibt-split-sticky{ position:sticky; top:0; height:100vh; overflow:hidden; }
.tibt-split-reveal{
  position:absolute; inset:0; display:flex; flex-direction:column;
  align-items:center; justify-content:center; text-align:center;
  padding:24px; background:#fff;
}
.tibt-split-reveal h2{ margin:0 0 14px; font-size:clamp(28px,5vw,48px); font-weight:800; letter-spacing:-0.02em; color:var(--ink); }
.tibt-split-reveal p{ max-width:520px; margin:0 0 26px; font-size:16px; line-height:1.5; color:var(--ink-soft); }
.tibt-split-reveal-actions{ display:flex; gap:16px; flex-wrap:wrap; justify-content:center; }
.tibt-split-btn{
  display:inline-block; padding:13px 28px; border-radius:8px;
  font-size:15px; font-weight:700; text-decoration:none; color:#fff;
  transition:transform .15s ease, opacity .15s ease;
}
.tibt-split-btn:hover{ transform:translateY(-2px); opacity:.92; text-decoration:none; }
.tibt-split-btn-dem{ background:var(--dem); }
.tibt-split-btn-rep{ background:var(--rep); }
.tibt-split-panel{
  position:absolute; top:0; bottom:0; width:50%;
  display:flex; align-items:center; justify-content:center;
  will-change:transform; z-index:2;
  transition:transform .7s cubic-bezier(.22,1,.36,1);
}
.tibt-split-panel-left{ left:0; background:var(--dem); justify-content:flex-end; padding-right:6%; transform:translateX(0); }
.tibt-split-panel-right{ right:0; background:var(--rep); justify-content:flex-start; padding-left:6%; transform:translateX(0); }
#tibt-split-scroll.is-open .tibt-split-panel-left{ transform:translateX(-100%); }
#tibt-split-scroll.is-open .tibt-split-panel-right{ transform:translateX(100%); }
.tibt-split-panel-text{ color:#fff; font-size:clamp(22px,4vw,40px); font-weight:800; line-height:1.15; letter-spacing:-0.01em; text-align:center; }

/* Dynamic polling-leader photos inside each split panel */
.tibt-split-leaders{ display:flex; flex-direction:column; align-items:center; gap:14px; max-width:260px; }
.tibt-split-leader-lg{ display:flex; flex-direction:column; align-items:center; gap:8px; }
.tibt-split-leader-link{ display:block; transition:transform .15s ease, opacity .15s ease; }
.tibt-split-leader-link:hover{ transform:translateY(-2px); opacity:.9; }
.tibt-split-leader-lg img{
  width:150px; height:150px; object-fit:cover; border-radius:12px;
  box-shadow:0 16px 32px -14px rgba(0,0,0,.55); border:3px solid rgba(255,255,255,.85);
}
.tibt-split-leader-name{ color:#fff; font-size:14px; font-weight:700; text-align:center; letter-spacing:-0.01em; }
.tibt-split-leader-row{ display:flex; gap:8px; justify-content:center; flex-wrap:wrap; max-width:240px; }
.tibt-split-leader-sm{ display:flex; flex-direction:column; align-items:center; gap:4px; width:56px; }
.tibt-split-leader-sm img{
  width:48px; height:48px; object-fit:cover; border-radius:8px;
  box-shadow:0 8px 16px -8px rgba(0,0,0,.5); border:2px solid rgba(255,255,255,.75);
}
.tibt-split-leader-sm .tibt-split-leader-name{ font-size:9.5px; font-weight:600; line-height:1.2; }
@media (max-width:680px){
  .tibt-split-panel-text{ font-size:22px; }
  .tibt-split-reveal p{ font-size:14px; }
  .tibt-split-leader-lg img{ width:100px; height:100px; }
  .tibt-split-leader-sm{ width:44px; }
  .tibt-split-leader-sm img{ width:36px; height:36px; }
  .tibt-split-leader-row{ max-width:180px; }
}
@media (prefers-reduced-motion: reduce){
  #tibt-split-scroll{ height:auto; }
  .tibt-split-sticky{ position:relative; height:auto; padding:60px 0; }
  .tibt-split-reveal{ position:relative; }
  .tibt-split-panel{ display:none; }
}

/* ================================================================
   Homepage: shop columns
================================================================ */
.tibt-shop-row{ max-width:1280px; margin:0 auto; padding:56px 24px; display:grid; grid-template-columns:1fr 1fr; gap:32px; }
.tibt-shop-col h2{ font-size:20px; font-weight:800; margin:0 0 18px; }
.tibt-shop-col.dem h2{ color:var(--dem); }
.tibt-shop-col.rep h2{ color:var(--rep); }
@media (max-width:680px){ .tibt-shop-row{ grid-template-columns:1fr; } }

/* Homepage shop columns: 3 products per side (wider cards than the 4-up shop archive) */
.tibt-shop-col .woocommerce ul.products{
	grid-template-columns:repeat(3,1fr) !important;
	gap:36px 22px;
}
@media (max-width:920px){ .tibt-shop-col .woocommerce ul.products{ grid-template-columns:repeat(2,1fr) !important; } }
@media (max-width:680px){ .tibt-shop-col .woocommerce ul.products{ grid-template-columns:repeat(2,1fr) !important; gap:28px 14px; } }
@media (max-width:420px){ .tibt-shop-col .woocommerce ul.products{ grid-template-columns:1fr !important; } }

/* ================================================================
   Homepage: Kalshi odds + our poll widgets
================================================================ */
#tibt-kalshi-widget, #tibt-poll-widget{
  --ink-primary:var(--ink); --ink-secondary:var(--ink-soft); --ink-muted:#888;
  --surface:#fff; --surface-2:var(--paper-2); --dem-w:var(--dem); --rep-w:var(--rep);
  max-width:860px; margin:0 auto; padding:32px 24px; box-sizing:border-box;
}
#tibt-kalshi-widget *, #tibt-poll-widget *{ box-sizing:border-box; }
.tibt-k-head, .tibt-p-head{ margin-bottom:14px; }
.tibt-k-head h3, .tibt-p-head h3{ margin:0 0 4px; font-size:22px; font-weight:700; letter-spacing:-0.01em; }
.tibt-k-sub, .tibt-p-sub{ font-size:13px; color:var(--ink-muted); }
.tibt-k-legend, .tibt-p-legend{ display:flex; gap:18px; margin-bottom:18px; }
.tibt-k-legend-item, .tibt-p-legend-item{ display:flex; align-items:center; gap:6px; font-size:13px; color:var(--ink-soft); }
.tibt-k-legend-item i, .tibt-p-legend-item i{ width:10px; height:10px; border-radius:2px; display:inline-block; }
.tibt-k-chart, .tibt-p-chart{ display:flex; flex-direction:column; gap:2px; }
.tibt-k-loading, .tibt-p-loading{ padding:40px 0; text-align:center; color:var(--ink-muted); font-size:14px; }
.tibt-k-row{ display:grid; grid-template-columns:150px 1fr 52px; align-items:center; gap:12px; padding:8px 10px; border-radius:6px; background:var(--paper-2); position:relative; }
.tibt-p-row{ display:grid; grid-template-columns:150px 1fr 52px 60px; align-items:center; gap:12px; padding:8px 10px; border-radius:6px; background:var(--paper-2); }
.tibt-k-name, .tibt-p-name{ font-size:14px; font-weight:600; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.tibt-k-track, .tibt-p-track{ position:relative; height:20px; background:#e9eaee; border-radius:4px; overflow:hidden; }
.tibt-k-fill, .tibt-p-fill{ position:absolute; left:0; top:0; bottom:0; border-radius:4px; min-width:4px; transition:width .6s ease; }
.tibt-k-pct, .tibt-p-pct{ font-size:14px; font-weight:700; text-align:right; font-variant-numeric:tabular-nums; }
.tibt-p-votes{ font-size:11px; color:var(--ink-muted); text-align:right; font-variant-numeric:tabular-nums; white-space:nowrap; }
.tibt-k-row:hover, .tibt-p-row:hover{ background:#eef0f4; }
.tibt-k-tooltip{
  position:absolute; bottom:100%; left:150px; transform:translateY(-6px);
  background:#1a1a1a; color:#fff; font-size:12px; padding:6px 10px; border-radius:6px;
  white-space:nowrap; opacity:0; pointer-events:none; transition:opacity .15s ease; z-index:2;
  max-width:calc(100vw - 40px); overflow:hidden; text-overflow:ellipsis;
}
@media (max-width:480px){
  .tibt-k-tooltip{ left:96px; max-width:calc(100vw - 116px); }
}
.tibt-k-row:hover .tibt-k-tooltip{ opacity:1; }
.tibt-k-error, .tibt-p-empty, .tibt-p-error{
  padding:16px; background:var(--paper-2); border:1px solid var(--line); border-radius:8px;
  font-size:13px; color:var(--ink-soft); text-align:center;
}
.tibt-k-footnote, .tibt-p-footnote{ margin-top:16px; font-size:11px; color:var(--ink-muted); line-height:1.5; }
@media (max-width:480px){
  .tibt-k-row{ grid-template-columns:96px 1fr 44px; }
  .tibt-p-row{ grid-template-columns:96px 1fr 40px 50px; }
  .tibt-k-name, .tibt-p-name{ font-size:12.5px; }
  .tibt-p-votes{ font-size:10px; }
}

/* ================================================================
   Homepage: house placeholder
================================================================ */
.tibt-placeholder{ text-align:center; padding:48px 20px; color:var(--ink-muted); }

/* Senate / House toss-up race sections */
.tibt-race-section{ max-width:1100px; margin:0 auto; padding:48px 24px 24px; }
.tibt-race-section-title{ font-size:26px; font-weight:800; margin:0 0 6px; letter-spacing:-0.01em; }
.tibt-race-section-sub{ font-size:14px; color:var(--ink-soft); margin:0 0 8px; max-width:640px; }
.tibt-race-row{ padding:32px 0; border-top:1px solid var(--line); }
.tibt-race-row-title{ font-size:18px; font-weight:700; margin:0 0 16px; }
.tibt-shop-row-compact{ max-width:none; padding:0 0 24px; gap:24px; }
.tibt-shop-row-compact .tibt-shop-col .woocommerce ul.products{
	grid-template-columns:1fr !important;
	max-width:260px;
	gap:0;
}
.tibt-shop-row-compact .tibt-shop-col.dem .woocommerce ul.products{ margin-left:0; margin-right:auto; }
.tibt-shop-row-compact .tibt-shop-col.rep .woocommerce ul.products{ margin-left:0; margin-right:auto; }
@media (max-width:680px){ .tibt-shop-row-compact{ grid-template-columns:1fr 1fr; } }

/* ================================================================
   Nav (Shop / Polls / Blog quick links)
================================================================ */
.site-nav ul{ list-style:none; display:flex; gap:22px; margin:0 22px 0 0; padding:0; }
.site-nav ul + ul{ margin-left:0; }

/* ================================================================
   Poll pages (single poll + /polls/ archive)
================================================================ */
.tibt-poll-page{ max-width:700px; }
.tibt-poll-eyebrow{ font-size:12px; font-weight:700; letter-spacing:.06em; text-transform:uppercase; color:var(--ink-muted); margin:0 0 14px; }
.tibt-poll-archive-dek{ color:var(--ink-soft); font-size:15px; margin:-8px 0 28px; }
.tibt-poll-back{ margin-top:8px; }
.tibt-poll-back a{ font-size:14px; font-weight:600; }
