/*
Theme Name: CalculatorGeek Tools Theme
Theme URI: https://calculatorgeek.com
Author: CalculatorGeek
Description: Clean, fast calculator tools theme with CPT, categories, popular calculators, ratings, usage stats, and calculator templates.
Version: 6.8.40
Text Domain: calculatorgeek
*/

/* =========================================================
 * Category archive (taxonomy) heading polish
 * ========================================================= */
.cg-term-title{
  display:flex;
  align-items:center;
  gap:12px;
  margin:0 0 6px;
}
.cg-term-title-icon{
  width:40px;
  height:40px;
  border-radius:12px;
  /* Match homepage category icon chip: soft blue bg + blue icon */
  background:rgba(14,165,233,.12);
  border:1px solid rgba(14,165,233,.22);
  color:#0ea5e9;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  flex:0 0 40px;
  box-shadow:none;
}
.cg-term-title-icon svg{
  width:20px;
  height:20px;
  stroke:currentColor;
  fill:none;
}

/* The global .cat-icon rule adds margin-bottom for homepage tiles.
   Inside the H1 chip we must remove that margin so the icon aligns perfectly. */
.cg-term-title-icon .cat-icon{ margin:0; }

.cg-term-desc{ margin:6px 0 0; }
.cg-term-readmore{ display:inline-block; margin-top:2px; }

/* Keep sub-category headings aligned */
.cg-subcat-title{
  display:flex;
  align-items:center;
  gap:10px;
}
.cg-term-desc{margin:6px 0 0;}
.cg-term-readmore{display:inline-block;margin-top:2px;}
.cg-term-meta{margin-top:4px;}

/* =========================
   Category page listing (2-column, reference style)
========================= */
.cg-term-group{ margin: 38px 0; }
.cg-term-group-title{ margin: 0 0 14px; font-weight: 800; padding-left: 22px; }

.cg-term-list{
  columns: 2;
  -webkit-columns: 2;
  -moz-columns: 2;
  column-gap: 56px;
  padding-left: 22px;
  margin: 0;
}
.cg-term-list li{
  break-inside: avoid;
  -webkit-column-break-inside: avoid;
  margin: 0 0 12px;
}
.cg-term-list a{
  text-decoration: underline;
  text-underline-offset: 3px;
}
@media (max-width: 820px){
  .cg-term-list{ columns: 1; -webkit-columns: 1; -moz-columns: 1; }
}

/* Most popular icon (homepage) */
.cg-mostpop-icon{ display:flex; justify-content:center; margin: 0 0 10px; }
/* Most popular icon: keep at native size to avoid browser upscaling blur */
.cg-mostpop-icon img{ width:40px; height:40px; display:block; object-fit:contain; }

/* =========================
   Footer (Omni-like, professional)
========================= */
.cg-footer-omni{
  background: linear-gradient(180deg, #11162b 0%, #0f1427 55%, #0e1326 100%) !important;
  color: rgba(255,255,255,.82);
  position: relative;
  z-index: 2;
  padding: 0;
}
.cg-footer-omni .cg-footer-shell{
  background: transparent !important;
  border-radius: 0;
  overflow: visible;
  box-shadow: none;
}
.cg-footer-omni .cg-footer-top,
.cg-footer-omni .cg-footer-bottom{ background: transparent !important; }
.cg-footer-omni a{ color:rgba(255,255,255,.82) !important; text-decoration:none; }
.cg-footer-omni a:hover{ color:#fff; }
.cg-footer-top{ padding: 44px 0 28px; border-top: none; }
.cg-footer-wrap{
  display:grid;
  grid-template-columns: 1.35fr 1fr 1fr 1fr;
  gap: 56px;
}
.cg-footer-col h4{
  margin: 0 0 14px;
  color:#fff;
  font-size:16px;
  font-weight: 800;
}
.cg-footer-brandrow{ display:flex; align-items:center; gap:12px; margin-bottom: 14px; }
.cg-footer-col.brand{ display:flex; flex-direction:column; align-items:flex-start; }
.cg-footer-logo{ width:auto; height:auto; border-radius:0; object-fit:contain; margin: 0 0 10px; }
.cg-footer-logoimg{ height:40px; width:auto; max-width:240px; display:block; margin: 0 0 10px; }
.cg-footer-logo--fallback{ display:flex; align-items:center; justify-content:flex-start; background:transparent; color:#fff; font-weight:900; border:none; border-radius:0; padding:0; }
.cg-footer-cats{ display:grid; grid-template-columns:repeat(2, minmax(0,1fr)); column-gap:28px; row-gap:10px; }
@media (max-width: 720px){
  .cg-footer-cats{ grid-template-columns:repeat(2, minmax(0,1fr)); }
}
@media (max-width: 480px){
  .cg-footer-cats{ grid-template-columns:1fr; }
}
.cg-footer-brandname{ font-weight:900; color:#fff; letter-spacing:.2px; font-size:28px; line-height:1.1; max-width:260px; }
.cg-footer-about{ margin: 0; max-width: 340px; line-height: 1.6; color: rgba(255,255,255,.78); }
.cg-footer-links{ list-style:none; padding:0; margin:0; }
.cg-footer-links li{ margin: 11px 0; }
.cg-footer-links a{ font-weight: 600; }

.cg-footer-social{ display:flex; gap:10px; margin: 4px 0 14px; flex-wrap:wrap; }
.cg-social{
  width:44px; height:44px;
  border-radius:999px;
  background: rgba(255,255,255,.08);
  display:inline-flex;
  align-items:center;
  justify-content:center;
  font-weight:800;
  color:#fff;
  border:1px solid rgba(255,255,255,.10);
}
.cg-social:hover{ background: rgba(255,255,255,.14); }

.cg-footer-contact a{ display:inline-block; margin-top: 4px; }

.cg-footer-bottom{ border-top:1px solid rgba(255,255,255,.10); padding: 18px 0; }
.cg-footer-bottom-inner{ display:flex; justify-content:space-between; align-items:center; gap:16px; }
.cg-footer-copy{ font-size: 13px; color: rgba(255,255,255,.70); text-align:left; }

@media (max-width: 980px){
  .cg-footer-wrap{ grid-template-columns: 1fr 1fr; }
  .cg-footer-top{ padding: 36px 0 22px; }
  .cg-footer-bottom{ padding: 16px 0; }
}
@media (max-width: 560px){
  .cg-footer-wrap{ grid-template-columns: 1fr; }
  .cg-footer-top{ padding: 30px 0 18px; }
  .cg-footer-bottom{ padding: 14px 0; }
}
/* v6.8.21+ footer extra-compact + centered copyright (no builder text) */
.cg-footer-top{ padding: 12px 0 8px !important; }
.cg-footer-bottom{ padding: 6px 0 !important; }
.cg-footer-wrap{ gap: 30px !important; }
.cg-footer-col h4{ margin-bottom: 8px !important; }
.cg-footer-links li{ margin: 6px 0 !important; }
.cg-footer-social{ margin: 2px 0 8px !important; }
.cg-social{ width:40px; height:40px; }
.cg-footer-bottom-inner{ display:flex !important; justify-content:center; align-items:center; }
.cg-footer-copy{ text-align:center !important; }

@media (max-width: 980px){
  .cg-footer-top{ padding: 10px 0 8px !important; }
  .cg-footer-bottom{ padding: 6px 0 !important; }
  .cg-footer-wrap{ gap: 24px !important; }
}
@media (max-width: 560px){
  .cg-footer-top{ padding: 10px 0 8px !important; }
  .cg-footer-bottom{ padding: 6px 0 !important; }
  .cg-footer-wrap{ gap: 18px !important; }
}

/* =========================
   Header auth buttons
========================= */
.cg-auth-cta{ display:flex; align-items:center; gap:10px; margin-left:14px; }
.cg-auth-cta .btn{ white-space:nowrap; }
.btn.btn-ghost{
  background: transparent;
  border: 1px solid rgba(2,132,199,.35);
  color: #0b2b3b;
  border-radius: 999px;
  padding: 10px 14px;
  font-weight: 700;
}
.btn.btn-ghost:hover{ background: rgba(56,189,248,.10); }

/* =========================
   Auth pages (Login/Signup)
========================= */
.cg-auth-wrap{ display:flex; justify-content:center; padding: 40px 16px; }
.cg-auth-card{
  position: relative;
  width: 100%;
  max-width: 430px;
  background: #fff;
  border-radius: 18px;
  box-shadow: 0 18px 50px rgba(15,23,42,.12);
  padding: 28px 24px;
}
.cg-auth-close{ position:absolute; right:14px; top:12px; width:34px; height:34px; border-radius:999px; display:flex; align-items:center; justify-content:center; color:#0f172a; text-decoration:none; }
.cg-auth-close:hover{ background: rgba(15,23,42,.06); }
.cg-auth-close span{ font-size: 22px; line-height: 1; }

.cg-auth-tabs{ display:flex; justify-content:space-between; gap:16px; padding: 6px 6px 18px; }
.cg-auth-tab{ flex:1; text-align:center; padding: 12px 10px; text-decoration:none; color:#0f172a; font-weight: 700; border-bottom: 2px solid transparent; }
.cg-auth-tab.is-active{ color:#0284c7; border-bottom-color:#0284c7; }

.cg-auth-subtitle{ text-align:center; color:#64748b; font-weight: 600; margin: 6px 0 18px; }
.cg-auth-form{ display:flex; flex-direction:column; gap: 12px; }
.cg-auth-field input{
  width:100%;
  border: 2px solid rgba(2,132,199,.35);
  border-radius: 10px;
  padding: 12px 14px;
  font-size: 15px;
  outline: none;
}
.cg-auth-field input:focus{ border-color:#0284c7; box-shadow: 0 0 0 4px rgba(56,189,248,.18); }
.cg-auth-field.has-eye{ position:relative; }
.cg-auth-eye{ position:absolute; right:10px; top:50%; transform:translateY(-50%); background:transparent; border:0; cursor:pointer; font-size:16px; }

.cg-auth-btn{
  width:100%;
  border:0;
  border-radius: 12px;
  padding: 12px 14px;
  font-weight: 800;
  cursor:pointer;
  color:#fff;
  background: linear-gradient(90deg, #0ea5e9, #22c55e);
  transition: background .18s ease, transform .12s ease;
}
.cg-auth-btn:hover{
  /* Slightly deeper on hover (requested) */
  background: linear-gradient(90deg, #0284c7, #16a34a);
}

/* Ensure signup/login primary button never turns white due to any global hover rules */
.cg-auth-modal .cg-auth-btn:hover,
.cg-auth-modal .cg-auth-btn:focus,
.cg-auth-modal .cg-auth-btn:focus-visible{
  background: linear-gradient(90deg, #0284c7, #16a34a) !important;
  color:#fff !important;
}
.cg-auth-btn:active{ transform: translateY(1px); }
.cg-auth-btn-outline{ background: #fff; color:#0f172a; border: 1px solid rgba(148,163,184,.65); }
.cg-auth-btn-outline:disabled{ opacity: .55; cursor:not-allowed; }
.cg-auth-provider{ display:inline-block; width: 18px; text-align:center; margin-right: 8px; font-weight:900; }

/* OAuth buttons (Google / Apple) */
.cg-auth-oauth{
  width:100%;
  height: 46px;
  border-radius: 12px;
  background:#fff;
  border: 1px solid rgba(148,163,184,.65);
  display:flex;
  align-items:center;
  justify-content:center;
  gap: 10px;
  color:#0f172a;
  font-weight: 700;
  cursor:pointer;
  text-decoration:none;
  transition: background .15s ease, border-color .15s ease, transform .12s ease;
}
.cg-auth-oauth:visited{ color:#0f172a; }
.cg-auth-oauth:hover{
  background: rgba(241,245,249,.75);
  border-color: rgba(100,116,139,.55);
}
.cg-auth-oauth:active{ transform: translateY(1px); }
.cg-auth-oauth__icon{ width: 18px; height: 18px; display:inline-flex; }
.cg-auth-oauth__icon svg{ width: 18px; height: 18px; display:block; }

.cg-auth-link{ text-align:center; color:#0284c7; font-weight: 700; text-decoration:none; margin-top: 2px; }
.cg-auth-link:hover{ text-decoration:underline; }
.cg-auth-sep{ display:flex; align-items:center; gap: 12px; margin: 10px 0 2px; color:#94a3b8; font-weight: 800; justify-content:center; }
.cg-auth-sep:before, .cg-auth-sep:after{ content:""; flex:1; height:1px; background: rgba(148,163,184,.45); }
.cg-auth-sep span{ padding: 0 2px; }
.cg-auth-legal{ text-align:center; color:#94a3b8; font-size: 13px; margin-top: 8px; }
.cg-auth-legal a{ color:#0284c7; text-decoration:underline; }
.cg-auth-error{ background: rgba(239,68,68,.08); border: 1px solid rgba(239,68,68,.25); color:#b91c1c; padding: 10px 12px; border-radius: 12px; margin: 2px 0 12px; }
.cg-auth-back{ display:inline-flex; align-items:center; gap:8px; color:#0284c7; font-weight: 800; text-decoration:none; margin: 2px 0 10px; }
.sr-only{ position:absolute; left:-9999px; width:1px; height:1px; overflow:hidden; }

/* =========================
 * Auth Modal (Login / Signup)
 * ========================= */
html.cg-modal-open, body.cg-modal-open{ overflow:hidden; }
.cg-auth-modal{ position:fixed; inset:0; z-index:100000; display:none; }
.cg-auth-modal.is-open{ display:block; }
.cg-auth-modal__backdrop{ position:absolute; inset:0; background:rgba(15,23,42,.55); backdrop-filter: blur(2px); }
.cg-auth-modal__dialog{
  position:relative;
  width:min(420px, calc(100vw - 32px));
  margin: 60px auto;
  background:#fff;
  border-radius:18px;
  padding:18px 18px 16px;
  box-shadow: 0 18px 60px rgba(2,6,23,.25);
}
.cg-auth-modal .cg-auth-close{
  position:absolute;
  right:12px;
  top:10px;
  width:34px;
  height:34px;
  border-radius:10px;
  border:1px solid rgba(148,163,184,.45);
  background:#fff;
  font-size:22px;
  line-height:1;
  cursor:pointer;
}
.cg-auth-modal .cg-auth-tabs{ display:flex; gap:12px; justify-content:center; margin: 8px 0 14px; }
.cg-auth-modal .cg-auth-tab{
  border:0;
  background:transparent;
  font-weight:600;
  padding:10px 14px;
  border-bottom:2px solid transparent;
  color:#0f172a;
  cursor:pointer;
}
.cg-auth-modal .cg-auth-tab.is-active{ color:#0ea5e9; border-bottom-color:#0ea5e9; }
.cg-auth-modal .cg-auth-error{
  background:rgba(239,68,68,.10);
  border:1px solid rgba(239,68,68,.25);
  padding:10px 12px;
  border-radius:12px;
  margin: 0 0 12px;
  color:#b91c1c;
  font-weight:500;
}

@media (max-width: 480px){
  .cg-auth-modal__dialog{ margin: 44px auto; }
}
