/*
Theme Name: What Is My Error (Child)
Theme URI: https://whatismyerror.com
Description: Child theme of iKnowledgeBase for whatismyerror.com — custom homepage with hero search, brand logo/banner, cleaned category labels, and theme options.
Author: Ranjan Mallick
Template: iknowledgebase
Version: 1.0.2
Text Domain: wime-child
*/

:root{
  --wime-ink: #16234F;
  --wime-paper: #F7F8FA;
  --wime-card: #FFFFFF;
  --wime-accent: #3457D5;
  --wime-accent-deep: #16234F;
  --wime-signal: #FF5A36;
  --wime-mist: #C7CEDB;
  --wime-mist-dark: #5B6584;
  --wime-border: rgba(22,35,79,0.10);
}

/* ---------- global type / branding ---------- */
body{
  background: var(--wime-paper);
  color: var(--wime-ink);
}
a{ color: var(--wime-accent); }
a:hover{ color: var(--wime-accent-deep); }

.site-branding .custom-logo,
.site-logo img{
  max-height: 52px;
  width: auto;
}

/* ---------- hero banner ---------- */
.wime-hero{
  position: relative;
  overflow: hidden;
  border-radius: 0 0 20px 20px;
  margin-bottom: 48px;
  background: var(--wime-paper);
}
.wime-hero img.wime-hero-bg{
  display: block;
  width: 100%;
  height: auto;
}
.wime-hero-content{
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
}
.wime-hero-inner{
  max-width: 900px;
  padding: 0 6% 0 6%;
}
.wime-hero-eyebrow{
  font-family: ui-monospace, "SF Mono", "Cascadia Code", Consolas, monospace;
  font-size: 13px;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--wime-mist-dark);
  margin: 0 0 10px;
}
.wime-hero-title{
  font-size: clamp(28px, 4vw, 46px);
  font-weight: 800;
  line-height: 1.12;
  margin: 0 0 14px;
  color: var(--wime-ink);
}
.wime-hero-title .accent{ color: var(--wime-signal); }
.wime-hero-sub{
  font-size: 16px;
  line-height: 1.6;
  color: var(--wime-mist-dark);
  max-width: 52ch;
  margin: 0 0 22px;
}

/* ---------- search form ---------- */
.wime-search-form{
  display: flex;
  gap: 10px;
  max-width: 520px;
}
.wime-search-form input[type="search"],
.wime-search-form input[type="text"]{
  flex: 1;
  font-family: ui-monospace, "SF Mono", "Cascadia Code", Consolas, monospace;
  font-size: 15px;
  padding: 14px 16px;
  border-radius: 12px;
  border: 1px solid var(--wime-mist);
  background: var(--wime-card);
  color: var(--wime-ink);
}
.wime-search-form input[type="search"]::placeholder{ color: #9AA2B8; }
.wime-search-form button{
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  border: none;
  border-radius: 10px;
  background: var(--wime-accent);
  color: #fff;
  cursor: pointer;
}
.wime-search-form button:hover{ background: var(--wime-accent-deep); }

/* ---------- category cards ---------- */
.wime-cat-grid{
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
  margin: 0 0 48px;
}
.wime-cat-card{
  background: var(--wime-card);
  border: 1px solid var(--wime-border);
  border-radius: 14px;
  padding: 20px;
}
.wime-cat-card-head{
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}
.wime-cat-card-head h2{
  font-size: 16px;
  margin: 0;
  text-transform: capitalize;
}
.wime-cat-count{
  font-size: 12px;
  font-weight: 700;
  background: var(--wime-paper);
  color: var(--wime-mist-dark);
  border-radius: 20px;
  padding: 2px 10px;
}
.wime-cat-card ul{ list-style: none; margin: 0 0 14px; padding: 0; }
.wime-cat-card li{ padding: 7px 0; border-bottom: 1px dashed var(--wime-border); font-size: 14.5px; }
.wime-cat-card li:last-child{ border-bottom: none; }
.wime-cat-card li a{ color: var(--wime-ink); text-decoration: none; }
.wime-cat-card li a:hover{ color: var(--wime-accent); }
.wime-view-all{
  display: inline-block;
  font-size: 13.5px;
  font-weight: 600;
  border: 1px solid var(--wime-mist);
  border-radius: 8px;
  padding: 7px 14px;
  color: var(--wime-accent);
  text-decoration: none;
}
.wime-view-all:hover{ background: var(--wime-accent); color:#fff; border-color: var(--wime-accent); }

/* ---------- search results ---------- */
.wime-results-list{ list-style:none; margin:0; padding:0; }
.wime-results-list li{
  background: var(--wime-card);
  border: 1px solid var(--wime-border);
  border-radius: 12px;
  padding: 18px 20px;
  margin-bottom: 14px;
}
.wime-results-list .wime-result-cat{
  font-family: ui-monospace, "SF Mono", Consolas, monospace;
  font-size: 12px;
  letter-spacing: .5px;
  text-transform: uppercase;
  color: var(--wime-accent);
}
.wime-results-list h2{ font-size: 19px; margin: 4px 0 8px; }
.wime-results-list h2 a{ color: var(--wime-ink); text-decoration:none; }
.wime-results-list p{ color: var(--wime-mist-dark); margin:0; font-size:14.5px; }
.wime-no-results{
  background: var(--wime-card);
  border: 1px dashed var(--wime-mist);
  border-radius: 12px;
  padding: 28px;
  text-align: center;
  color: var(--wime-mist-dark);
}

/* ---------- responsive ---------- */
@media (max-width: 680px){
  .wime-hero-flex{ padding: 32px 6% 12px !important; }
  .wime-hero-deco{ max-width: 55% !important; opacity: .8; margin: 0 auto; }
  .wime-cat-grid{ margin-top: 8px; }
}

/* ---------- misc fixes ---------- */
.wime-hide-post-views .post-views,
.wime-hide-post-views .wme-post-views,
.wime-hide-post-views [class*="post-view"]{
  display: none !important;
}
