/*
Theme Name: AI Tools Daily
Theme URI: https://aitoolsdaily.net
Author: AI Tools Daily Team
Description: A professional AI tools review and guide blog theme
Version: 1.0
License: GNU General Public License v2 or later
Text Domain: aitoolsdaily
*/

/* ========== GOOGLE FONTS ========== */
@import url('https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@400;500;600;700&family=Inter:wght@400;500;600&display=swap');

/* ========== RESET & BASE ========== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --navy:    #0D1117;
  --blue:    #2563EB;
  --blue-lt: #EFF6FF;
  --blue-md: #DBEAFE;
  --dark:    #1E3A5F;
  --body:    #334155;
  --meta:    #64748B;
  --border:  #E2E8F0;
  --bg:      #FFFFFF;
  --bg2:     #F8FAFC;
  --radius:  10px;
  --shadow:  0 2px 16px rgba(37,99,235,0.08);
  --shadow-hover: 0 6px 28px rgba(37,99,235,0.16);
}

html { scroll-behavior: smooth; }

body {
  font-family: 'Inter', sans-serif;
  font-size: 16px;
  line-height: 1.7;
  color: var(--body);
  background: var(--bg);
}

a { color: var(--blue); text-decoration: none; transition: color 0.2s; }
a:hover { color: var(--dark); }
img { max-width: 100%; height: auto; display: block; }

h1,h2,h3,h4,h5 {
  font-family: 'Space Grotesk', sans-serif;
  color: var(--dark);
  line-height: 1.3;
  font-weight: 700;
}

/* ========== CONTAINER ========== */
.container { max-width: 1160px; margin: 0 auto; padding: 0 24px; }

/* ========== HEADER / NAV ========== */
.site-header {
  background: var(--navy);
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 2px 20px rgba(0,0,0,0.3);
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 24px;
  max-width: 1160px;
  margin: 0 auto;
  height: 68px;
}

.site-logo {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 22px;
  font-weight: 700;
  color: #FFFFFF;
  display: flex;
  align-items: center;
  gap: 10px;
}

.site-logo .logo-icon {
  width: 34px;
  height: 34px;
  background: var(--blue);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  animation: pulse-glow 3s ease-in-out infinite;
}

@keyframes pulse-glow {
  0%, 100% { box-shadow: 0 0 0 0 rgba(37,99,235,0.4); }
  50% { box-shadow: 0 0 0 8px rgba(37,99,235,0); }
}

.site-logo span { color: var(--blue); }
.site-logo:hover { color: #fff; }

.main-nav { display: flex; align-items: center; gap: 6px; }

.main-nav a {
  color: #CBD5E1;
  font-size: 14px;
  font-weight: 500;
  padding: 8px 14px;
  border-radius: 6px;
  transition: all 0.2s;
  white-space: nowrap;
}

.main-nav a:hover {
  color: #fff;
  background: rgba(37,99,235,0.3);
}

.main-nav a.current {
  color: #fff;
  background: var(--blue);
}

.nav-search {
  background: rgba(255,255,255,0.1);
  border: 1px solid rgba(255,255,255,0.15);
  color: #fff;
  padding: 8px 14px;
  border-radius: 6px;
  font-size: 14px;
  width: 180px;
  outline: none;
  transition: all 0.2s;
}

.nav-search::placeholder { color: #94A3B8; }
.nav-search:focus { background: rgba(255,255,255,0.15); border-color: var(--blue); width: 220px; }

/* ========== HERO SECTION ========== */
.hero {
  background: linear-gradient(135deg, #0D1117 0%, #1E3A5F 50%, #0D1117 100%);
  padding: 80px 0 70px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: -60px; left: 50%; transform: translateX(-50%);
  width: 600px; height: 600px;
  background: radial-gradient(circle, rgba(37,99,235,0.15) 0%, transparent 70%);
  pointer-events: none;
}

.hero-tag {
  display: inline-block;
  background: rgba(37,99,235,0.2);
  border: 1px solid rgba(37,99,235,0.4);
  color: #93C5FD;
  font-size: 13px;
  font-weight: 600;
  padding: 6px 16px;
  border-radius: 20px;
  margin-bottom: 24px;
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

.hero h1 {
  font-size: clamp(32px, 5vw, 54px);
  color: #FFFFFF;
  margin-bottom: 20px;
  max-width: 700px;
  margin-left: auto;
  margin-right: auto;
}

.hero h1 span { color: #60A5FA; }

.hero p {
  font-size: 18px;
  color: #94A3B8;
  max-width: 520px;
  margin: 0 auto 36px;
  line-height: 1.7;
}

.hero-btns { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }

.btn-primary {
  background: var(--blue);
  color: #fff;
  padding: 14px 28px;
  border-radius: var(--radius);
  font-weight: 600;
  font-size: 15px;
  transition: all 0.2s;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.btn-primary:hover {
  background: #1D4ED8;
  color: #fff;
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(37,99,235,0.35);
}

.btn-secondary {
  background: rgba(255,255,255,0.08);
  color: #CBD5E1;
  padding: 14px 28px;
  border-radius: var(--radius);
  font-weight: 600;
  font-size: 15px;
  border: 1px solid rgba(255,255,255,0.15);
  transition: all 0.2s;
}

.btn-secondary:hover {
  background: rgba(255,255,255,0.14);
  color: #fff;
}

/* ========== CATEGORY PILLS ========== */
.categories-bar {
  background: var(--bg);
  border-bottom: 1px solid var(--border);
  padding: 0;
}

.cat-pills {
  display: flex;
  gap: 0;
  overflow-x: auto;
  scrollbar-width: none;
}

.cat-pills::-webkit-scrollbar { display: none; }

.cat-pill {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 18px 22px;
  font-size: 14px;
  font-weight: 600;
  color: var(--meta);
  border-bottom: 3px solid transparent;
  white-space: nowrap;
  transition: all 0.2s;
}

.cat-pill:hover {
  color: var(--blue);
  border-bottom-color: var(--blue-md);
}

.cat-pill.active {
  color: var(--blue);
  border-bottom-color: var(--blue);
}

.cat-pill .pill-icon {
  width: 28px;
  height: 28px;
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
}

/* ========== SECTION TITLES ========== */
.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 32px;
}

.section-title {
  font-size: 24px;
  font-weight: 700;
  color: var(--dark);
  display: flex;
  align-items: center;
  gap: 10px;
}

.section-title::before {
  content: '';
  width: 4px;
  height: 24px;
  background: var(--blue);
  border-radius: 2px;
  display: inline-block;
}

.section-link {
  font-size: 14px;
  font-weight: 600;
  color: var(--blue);
  display: flex;
  align-items: center;
  gap: 4px;
}

/* ========== ARTICLE CARDS ========== */
.articles-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.article-card {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  transition: all 0.3s;
}

.article-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-hover);
  border-color: var(--blue-md);
}

.card-img {
  width: 100%;
  height: 200px;
  object-fit: cover;
}

.card-img-placeholder {
  width: 100%;
  height: 200px;
  background: linear-gradient(135deg, var(--blue-lt), var(--blue-md));
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 48px;
}

.card-body { padding: 20px; }

.card-cat {
  display: inline-block;
  background: var(--blue-lt);
  color: var(--blue);
  font-size: 12px;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 4px;
  margin-bottom: 12px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.card-title {
  font-size: 17px;
  font-weight: 700;
  color: var(--dark);
  margin-bottom: 10px;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.card-title a { color: inherit; }
.card-title a:hover { color: var(--blue); }

.card-excerpt {
  font-size: 14px;
  color: var(--meta);
  line-height: 1.6;
  margin-bottom: 16px;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.card-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 13px;
  color: var(--meta);
  padding-top: 14px;
  border-top: 1px solid var(--border);
}

.card-meta-left { display: flex; align-items: center; gap: 6px; }
.read-more { color: var(--blue); font-weight: 600; font-size: 13px; }
.read-more:hover { color: var(--dark); }

/* ========== FEATURED ARTICLE ========== */
.featured-article {
  background: var(--navy);
  border-radius: 14px;
  overflow: hidden;
  display: grid;
  grid-template-columns: 1fr 1fr;
  margin-bottom: 48px;
  min-height: 320px;
}

.featured-content {
  padding: 40px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.featured-tag {
  display: inline-block;
  background: var(--blue);
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  padding: 5px 12px;
  border-radius: 4px;
  margin-bottom: 18px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.featured-title {
  font-size: 28px;
  color: #fff;
  margin-bottom: 14px;
  line-height: 1.3;
}

.featured-excerpt { color: #94A3B8; font-size: 15px; line-height: 1.7; margin-bottom: 24px; }

.featured-img {
  background: linear-gradient(135deg, #1E3A5F, #2563EB);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 80px;
}

/* ========== CATEGORY SHOWCASE ========== */
.cat-showcase {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-bottom: 48px;
}

.cat-card {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px 20px;
  text-align: center;
  transition: all 0.25s;
  cursor: pointer;
}

.cat-card:hover {
  border-color: var(--blue);
  background: var(--blue-lt);
  transform: translateY(-3px);
  box-shadow: var(--shadow);
}

.cat-card-icon {
  font-size: 36px;
  margin-bottom: 12px;
  display: block;
}

.cat-card-name {
  font-size: 15px;
  font-weight: 700;
  color: var(--dark);
  margin-bottom: 6px;
}

.cat-card-count {
  font-size: 13px;
  color: var(--meta);
}

/* ========== MAIN LAYOUT ========== */
.main-wrapper {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 40px;
  padding: 48px 0;
}

.content-area { min-width: 0; }

/* ========== SIDEBAR ========== */
.sidebar { }

.widget {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  margin-bottom: 24px;
}

.widget-title {
  font-size: 16px;
  font-weight: 700;
  color: var(--dark);
  margin-bottom: 18px;
  padding-bottom: 12px;
  border-bottom: 2px solid var(--blue-md);
}

/* About widget */
.about-widget { text-align: center; }
.about-icon { font-size: 48px; margin-bottom: 12px; }
.about-widget p { font-size: 14px; color: var(--meta); line-height: 1.6; }

/* Categories widget */
.cat-list { list-style: none; }
.cat-list li {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 0;
  border-bottom: 1px solid var(--border);
  font-size: 14px;
}
.cat-list li:last-child { border-bottom: none; }
.cat-list a { color: var(--body); font-weight: 500; }
.cat-list a:hover { color: var(--blue); }
.cat-list .count {
  background: var(--blue-lt);
  color: var(--blue);
  font-size: 12px;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 10px;
}

/* Newsletter widget */
.newsletter-widget { background: var(--navy); border-color: var(--navy); }
.newsletter-widget .widget-title { color: #fff; border-bottom-color: rgba(255,255,255,0.1); }
.newsletter-widget p { font-size: 14px; color: #94A3B8; margin-bottom: 16px; }
.newsletter-input {
  width: 100%;
  padding: 10px 14px;
  border-radius: 6px;
  border: 1px solid rgba(255,255,255,0.15);
  background: rgba(255,255,255,0.08);
  color: #fff;
  font-size: 14px;
  margin-bottom: 10px;
  outline: none;
}
.newsletter-input::placeholder { color: #64748B; }
.newsletter-btn {
  width: 100%;
  padding: 10px;
  background: var(--blue);
  color: #fff;
  border: none;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s;
}
.newsletter-btn:hover { background: #1D4ED8; }

/* ========== SINGLE POST ========== */
.post-header { margin-bottom: 32px; }

.post-category {
  display: inline-block;
  background: var(--blue-lt);
  color: var(--blue);
  font-size: 12px;
  font-weight: 700;
  padding: 5px 12px;
  border-radius: 4px;
  margin-bottom: 16px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.post-title {
  font-size: clamp(26px, 4vw, 38px);
  color: var(--dark);
  line-height: 1.25;
  margin-bottom: 16px;
}

.post-meta {
  display: flex;
  gap: 20px;
  font-size: 14px;
  color: var(--meta);
  margin-bottom: 24px;
  flex-wrap: wrap;
}

.post-meta span { display: flex; align-items: center; gap: 5px; }

.post-featured-img {
  width: 100%;
  border-radius: var(--radius);
  margin-bottom: 36px;
  max-height: 460px;
  object-fit: cover;
}

.post-content { font-size: 17px; line-height: 1.8; color: var(--body); }
.post-content h2 { font-size: 26px; color: var(--dark); margin: 36px 0 16px; }
.post-content h3 { font-size: 20px; color: var(--dark); margin: 28px 0 12px; }
.post-content p { margin-bottom: 20px; }
.post-content ul, .post-content ol { padding-left: 24px; margin-bottom: 20px; }
.post-content li { margin-bottom: 8px; }
.post-content strong { color: var(--dark); font-weight: 600; }

.post-content blockquote {
  border-left: 4px solid var(--blue);
  background: var(--blue-lt);
  padding: 18px 24px;
  margin: 28px 0;
  border-radius: 0 var(--radius) var(--radius) 0;
  font-style: italic;
  font-size: 18px;
  color: var(--dark);
}

.post-content table {
  width: 100%;
  border-collapse: collapse;
  margin: 24px 0;
  font-size: 15px;
}
.post-content th {
  background: var(--navy);
  color: #fff;
  padding: 12px 16px;
  text-align: left;
  font-family: 'Space Grotesk', sans-serif;
}
.post-content td {
  padding: 12px 16px;
  border-bottom: 1px solid var(--border);
}
.post-content tr:hover td { background: var(--blue-lt); }

/* ========== RATING BOX ========== */
.rating-box {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  margin: 28px 0;
}
.rating-score {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 52px;
  font-weight: 700;
  color: var(--blue);
  line-height: 1;
}
.rating-label { font-size: 14px; color: var(--meta); margin-top: 4px; }

/* ========== PROS CONS ========== */
.pros-cons {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin: 24px 0;
}
.pros { background: #F0FDF4; border: 1px solid #86EFAC; border-radius: var(--radius); padding: 20px; }
.cons { background: #FFF5F5; border: 1px solid #FCA5A5; border-radius: var(--radius); padding: 20px; }
.pros h4 { color: #166534; font-size: 15px; margin-bottom: 12px; }
.cons h4 { color: #991B1B; font-size: 15px; margin-bottom: 12px; }
.pros ul, .cons ul { padding-left: 18px; font-size: 14px; }
.pros li { color: #15803D; margin-bottom: 6px; }
.cons li { color: #DC2626; margin-bottom: 6px; }

/* ========== TOOL INFO BOX ========== */
.tool-info {
  background: var(--navy);
  border-radius: var(--radius);
  padding: 24px;
  margin: 28px 0;
  color: #CBD5E1;
}
.tool-info h4 { color: #fff; font-size: 16px; margin-bottom: 16px; }
.tool-info-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; }
.tool-info-item { font-size: 14px; }
.tool-info-label { color: #64748B; font-size: 12px; text-transform: uppercase; letter-spacing: 0.5px; margin-bottom: 4px; }
.tool-info-value { color: #E2E8F0; font-weight: 600; }

/* ========== PAGINATION ========== */
.pagination {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin: 48px 0;
}
.pagination a, .pagination span {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 600;
  border: 1px solid var(--border);
  color: var(--body);
  transition: all 0.2s;
}
.pagination a:hover { border-color: var(--blue); color: var(--blue); }
.pagination .current { background: var(--blue); color: #fff; border-color: var(--blue); }

/* ========== BREADCRUMB ========== */
.breadcrumb {
  font-size: 13px;
  color: var(--meta);
  padding: 14px 0;
  display: flex;
  align-items: center;
  gap: 8px;
}
.breadcrumb a { color: var(--blue); }
.breadcrumb span { color: var(--meta); }

/* ========== FOOTER ========== */
.site-footer {
  background: var(--navy);
  color: #94A3B8;
  margin-top: 64px;
}

.footer-top {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1fr;
  gap: 40px;
  padding: 56px 0 40px;
}

.footer-brand p {
  font-size: 14px;
  line-height: 1.7;
  margin-top: 14px;
  max-width: 260px;
}

.footer-logo {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 20px;
  font-weight: 700;
  color: #fff;
  display: flex;
  align-items: center;
  gap: 10px;
}

.footer-logo .logo-icon {
  width: 30px;
  height: 30px;
  background: var(--blue);
  border-radius: 7px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 15px;
}

.footer-logo span { color: var(--blue); }

.footer-col h4 {
  color: #fff;
  font-size: 15px;
  font-weight: 600;
  margin-bottom: 18px;
  font-family: 'Space Grotesk', sans-serif;
}

.footer-col ul { list-style: none; }
.footer-col ul li { margin-bottom: 10px; }
.footer-col ul a {
  color: #64748B;
  font-size: 14px;
  transition: color 0.2s;
}
.footer-col ul a:hover { color: #93C5FD; }

.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.07);
  padding: 20px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 13px;
}

.footer-bottom-links { display: flex; gap: 20px; }
.footer-bottom-links a { color: #64748B; font-size: 13px; }
.footer-bottom-links a:hover { color: #93C5FD; }

/* ========== PAGE ========== */
.page-content { padding: 48px 0; }
.page-title { font-size: 36px; color: var(--dark); margin-bottom: 28px; }
.page-body { font-size: 17px; line-height: 1.8; }
.page-body p { margin-bottom: 18px; }

/* ========== 404 ========== */
.error-404 { text-align: center; padding: 80px 0; }
.error-404 .error-code { font-size: 100px; color: var(--blue-md); font-weight: 700; }
.error-404 h2 { font-size: 28px; color: var(--dark); margin: 16px 0 12px; }
.error-404 p { color: var(--meta); margin-bottom: 28px; }

/* ========== SEARCH ========== */
.search-form {
  display: flex;
  gap: 10px;
  margin-bottom: 32px;
}
.search-input {
  flex: 1;
  padding: 12px 16px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-size: 15px;
  outline: none;
}
.search-input:focus { border-color: var(--blue); }
.search-btn {
  background: var(--blue);
  color: #fff;
  border: none;
  padding: 12px 20px;
  border-radius: var(--radius);
  font-weight: 600;
  cursor: pointer;
}

/* ========== RESPONSIVE ========== */
@media (max-width: 1024px) {
  .main-wrapper { grid-template-columns: 1fr; }
  .sidebar { display: none; }
  .footer-top { grid-template-columns: 1fr 1fr; }
  .cat-showcase { grid-template-columns: repeat(2, 1fr); }
  .articles-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 768px) {
  .nav-inner { flex-wrap: wrap; height: auto; padding: 14px 20px; gap: 10px; }
  .main-nav { flex-wrap: wrap; }
  .nav-search { display: none; }
  .hero { padding: 50px 0; }
  .featured-article { grid-template-columns: 1fr; }
  .featured-img { display: none; }
  .articles-grid { grid-template-columns: 1fr; }
  .cat-showcase { grid-template-columns: repeat(2, 1fr); }
  .footer-top { grid-template-columns: 1fr; }
  .footer-bottom { flex-direction: column; gap: 12px; text-align: center; }
  .pros-cons { grid-template-columns: 1fr; }
  .tool-info-grid { grid-template-columns: 1fr; }
}
