/*
Theme Name: EventCraft
Theme URI: https://birliman-catering.ru
Author: EventCraft Team
Author URI: https://birliman-catering.ru
Description: Стильная тема для блога об организации банкетов, фуршетов и кофе-брейков под ключ.
Version: 1.1
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: eventcraft
*/

/* ========== CSS VARIABLES ========== */
:root {
  --color-bg: #FFFFFF;
  --color-terracotta: #C06B4A;
  --color-terracotta-dark: #A55A3A;
  --color-saffron: #E3B37C;
  --color-saffron-light: #F5E6D0;
  --color-text: #2F2F2F;
  --color-text-light: #6B6B6B;
  --color-border: #E8E0D8;
  --color-bg-alt: #FAF7F4;
  --color-bg-dark: #3A3028;
  --color-white: #FFFFFF;
  --font-display: 'Playfair Display', Georgia, 'Times New Roman', serif;
  --font-body: 'Source Sans 3', 'Segoe UI', Tahoma, sans-serif;
  --radius: 6px;
  --shadow-card: 0 4px 24px rgba(47, 47, 47, 0.08);
  --shadow-hover: 0 8px 40px rgba(47, 47, 47, 0.14);
  --transition: 0.3s ease;
  --max-width: 1240px;
  --gap: 2rem;
}

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

html {
  scroll-behavior: smooth;
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.7;
  color: var(--color-text);
  background-color: var(--color-bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--color-terracotta);
  text-decoration: none;
  transition: color var(--transition);
}

a:hover,
a:focus {
  color: var(--color-terracotta-dark);
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--color-text);
  line-height: 1.25;
}

h1 { font-size: 2.4rem; }
h2 { font-size: 2rem; }
h3 { font-size: 1.5rem; }
h4 { font-size: 1.25rem; }

p { margin-bottom: 1em; }

ul, ol {
  margin: 0 0 1.2em 1.4em;
}

li {
  margin-bottom: 0.4em;
}

::selection {
  background: var(--color-saffron);
  color: var(--color-text);
}

/* ========== UTILITY ========== */
.container {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 1.5rem;
}

.screen-reader-text {
  clip: rect(1px, 1px, 1px, 1px);
  position: absolute !important;
  height: 1px;
  width: 1px;
  overflow: hidden;
  word-wrap: normal !important;
}

/* ========== HEADER ========== */
.site-header {
  background: var(--color-bg);
  border-bottom: 1px solid var(--color-border);
  position: relative;
  z-index: 100;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 0;
  gap: 1.5rem;
}

.site-branding {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  flex-shrink: 0;
}

.custom-logo-link img,
.site-logo-default {
  height: 48px;
  width: auto;
}

.site-logo-default {
  display: flex;
  align-items: center;
}

.site-title {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--color-text);
  line-height: 1.3;
}

.site-title a {
  color: inherit;
}

.site-title a:hover {
  color: var(--color-terracotta);
}

.site-description {
  display: none;
}

/* ========== NAVIGATION ========== */
.main-navigation {
  display: flex;
  align-items: center;
}

.nav-menu {
  display: flex;
  list-style: none;
  margin: 0;
  padding: 0;
  gap: 0.2rem;
}

.nav-menu li {
  margin: 0;
  position: relative;
}

.nav-menu a {
  display: block;
  padding: 0.5rem 1rem;
  font-family: var(--font-body);
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--color-text);
  letter-spacing: 0.02em;
  border-radius: var(--radius);
  transition: background var(--transition), color var(--transition);
}

.nav-menu a:hover,
.nav-menu .current-menu-item > a {
  color: var(--color-terracotta);
  background: var(--color-saffron-light);
}

/* Sub-menu */
.nav-menu .sub-menu {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  background: var(--color-bg);
  min-width: 220px;
  border-radius: var(--radius);
  box-shadow: var(--shadow-hover);
  border: 1px solid var(--color-border);
  padding: 0.5rem 0;
  z-index: 200;
  flex-direction: column;
}

.nav-menu li:hover > .sub-menu {
  display: flex;
}

.nav-menu .sub-menu a {
  padding: 0.45rem 1.2rem;
  font-size: 0.88rem;
  font-weight: 500;
}

/* Mobile toggle */
.menu-toggle {
  display: none;
  background: none;
  border: 2px solid var(--color-terracotta);
  border-radius: var(--radius);
  padding: 0.45rem 0.65rem;
  cursor: pointer;
  flex-direction: column;
  gap: 4px;
  align-items: center;
  justify-content: center;
}

.menu-toggle .bar {
  display: block;
  width: 22px;
  height: 2.5px;
  background: var(--color-terracotta);
  border-radius: 2px;
  transition: transform var(--transition), opacity var(--transition);
}

.menu-toggle[aria-expanded="true"] .bar:nth-child(1) {
  transform: translateY(6.5px) rotate(45deg);
}
.menu-toggle[aria-expanded="true"] .bar:nth-child(2) {
  opacity: 0;
}
.menu-toggle[aria-expanded="true"] .bar:nth-child(3) {
  transform: translateY(-6.5px) rotate(-45deg);
}

/* Header search */
.header-search {
  position: relative;
  flex-shrink: 0;
}

.header-search .search-field {
  border: 1px solid var(--color-border);
  border-radius: 30px;
  padding: 0.45rem 2.4rem 0.45rem 1rem;
  font-size: 0.88rem;
  font-family: var(--font-body);
  color: var(--color-text);
  background: var(--color-bg-alt);
  width: 200px;
  transition: border-color var(--transition), width var(--transition);
  outline: none;
}

.header-search .search-field:focus {
  border-color: var(--color-terracotta);
  width: 240px;
}

.header-search .search-submit {
  position: absolute;
  right: 8px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  cursor: pointer;
  color: var(--color-text-light);
  font-size: 1rem;
  padding: 0.2rem;
}

/* ========== HERO / FRONT-PAGE ========== */
.hero-section {
  background: linear-gradient(135deg, var(--color-bg-alt) 0%, var(--color-saffron-light) 100%);
  padding: 4rem 0 3rem;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.hero-section::before {
  content: '';
  position: absolute;
  top: -60px;
  right: -60px;
  width: 300px;
  height: 300px;
  background: radial-gradient(circle, rgba(192,107,74,0.1) 0%, transparent 70%);
  border-radius: 50%;
}

.hero-section::after {
  content: '';
  position: absolute;
  bottom: -40px;
  left: -40px;
  width: 200px;
  height: 200px;
  background: radial-gradient(circle, rgba(227,179,124,0.15) 0%, transparent 70%);
  border-radius: 50%;
}

.hero-content {
  position: relative;
  z-index: 1;
  max-width: 720px;
  margin: 0 auto;
}

.hero-title {
  font-family: var(--font-display);
  font-size: 2.6rem;
  color: var(--color-text);
  margin-bottom: 1rem;
  line-height: 1.2;
}

.hero-title span {
  color: var(--color-terracotta);
}

.hero-description {
  font-size: 1.1rem;
  color: var(--color-text-light);
  max-width: 560px;
  margin: 0 auto 1.8rem;
  line-height: 1.7;
}

.hero-cta {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 2rem;
  background: var(--color-terracotta);
  color: var(--color-white);
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 1rem;
  border-radius: var(--radius);
  transition: background var(--transition), transform var(--transition);
}

.hero-cta:hover {
  background: var(--color-terracotta-dark);
  color: var(--color-white);
  transform: translateY(-2px);
}

/* ========== AUTHOR BOX ========== */
.author-box {
  display: flex;
  align-items: center;
  gap: 1.2rem;
  background: var(--color-bg-alt);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: 1.5rem;
  margin: 2.5rem 0;
}

.author-avatar {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  overflow: hidden;
  flex-shrink: 0;
  background: var(--color-saffron-light);
  display: flex;
  align-items: center;
  justify-content: center;
}

.author-avatar svg {
  width: 40px;
  height: 40px;
  color: var(--color-terracotta);
}

.author-info h4 {
  font-family: var(--font-display);
  font-size: 1.1rem;
  margin-bottom: 0.25rem;
  color: var(--color-text);
}

.author-label {
  font-size: 0.82rem;
  color: var(--color-terracotta);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 0.3rem;
}

.author-info p {
  font-size: 0.92rem;
  color: var(--color-text-light);
  margin: 0;
  line-height: 1.5;
}

/* ========== CARDS GRID ========== */
.posts-section {
  padding: 3rem 0;
}

.section-heading {
  font-family: var(--font-display);
  font-size: 1.8rem;
  color: var(--color-text);
  text-align: center;
  margin-bottom: 2.5rem;
  position: relative;
}

.section-heading::after {
  content: '';
  display: block;
  width: 60px;
  height: 3px;
  background: var(--color-terracotta);
  margin: 0.8rem auto 0;
  border-radius: 2px;
}

.cards-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--gap);
}

/* Asymmetric layout: first card spans 2 columns */
.cards-grid .card-article:first-child {
  grid-column: span 2;
}

.cards-grid .card-article:first-child .card-thumb {
  height: 320px;
}

/* Card */
.card-article {
  background: var(--color-bg);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-card);
  transition: box-shadow var(--transition), transform var(--transition);
  display: flex;
  flex-direction: column;
}

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

.card-thumb {
  position: relative;
  overflow: hidden;
  height: 220px;
  background: var(--color-bg-alt);
}

.card-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.card-article:hover .card-thumb img {
  transform: scale(1.05);
}

.card-thumb-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--color-saffron-light) 0%, var(--color-bg-alt) 100%);
}

.card-thumb-placeholder svg {
  width: 56px;
  height: 56px;
  color: var(--color-saffron);
  opacity: 0.7;
}

.card-category {
  position: absolute;
  top: 12px;
  left: 12px;
  background: var(--color-terracotta);
  color: var(--color-white);
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 0.25rem 0.65rem;
  border-radius: var(--radius);
  z-index: 2;
}

.card-body {
  padding: 1.3rem 1.4rem 1.5rem;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.card-meta {
  display: flex;
  align-items: center;
  gap: 1rem;
  font-size: 0.8rem;
  color: var(--color-text-light);
  margin-bottom: 0.65rem;
}

.card-meta-item {
  display: flex;
  align-items: center;
  gap: 0.3rem;
}

.card-meta-item svg {
  width: 14px;
  height: 14px;
  color: var(--color-saffron);
}

.card-title {
  font-family: var(--font-display);
  font-size: 1.2rem;
  margin-bottom: 0.6rem;
  line-height: 1.35;
}

.card-title a {
  color: var(--color-text);
}

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

.card-excerpt {
  font-size: 0.92rem;
  color: var(--color-text-light);
  line-height: 1.6;
  flex: 1;
  margin-bottom: 1rem;
}

.card-excerpt a {
  color: var(--color-terracotta);
  text-decoration: underline;
}

.card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: auto;
}

.btn-read-more {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--color-terracotta);
  transition: gap var(--transition), color var(--transition);
}

.btn-read-more:hover {
  color: var(--color-terracotta-dark);
  gap: 0.65rem;
}

.btn-read-more svg {
  width: 16px;
  height: 16px;
}

/* ========== BUTTONS ========== */
.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.65rem 1.6rem;
  background: var(--color-terracotta);
  color: var(--color-white);
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.92rem;
  border: none;
  border-radius: var(--radius);
  cursor: pointer;
  transition: background var(--transition), transform var(--transition);
}

.btn-primary:hover {
  background: var(--color-terracotta-dark);
  color: var(--color-white);
  transform: translateY(-1px);
}

.btn-outline {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.6rem 1.4rem;
  background: transparent;
  color: var(--color-terracotta);
  border: 2px solid var(--color-terracotta);
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.88rem;
  border-radius: var(--radius);
  cursor: pointer;
  transition: background var(--transition), color var(--transition);
}

.btn-outline:hover {
  background: var(--color-terracotta);
  color: var(--color-white);
}

/* ========== PAGINATION ========== */
.pagination-wrap {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0.5rem;
  margin: 3rem 0 2rem;
  flex-wrap: wrap;
}

.pagination-wrap .page-numbers {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 42px;
  height: 42px;
  padding: 0 0.6rem;
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--color-text);
  transition: background var(--transition), color var(--transition), border-color var(--transition);
}

.pagination-wrap .page-numbers:hover {
  background: var(--color-saffron-light);
  border-color: var(--color-saffron);
  color: var(--color-terracotta);
}

.pagination-wrap .page-numbers.current {
  background: var(--color-terracotta);
  border-color: var(--color-terracotta);
  color: var(--color-white);
}

.pagination-wrap .page-numbers.dots {
  border: none;
  cursor: default;
}

/* ========== SINGLE POST ========== */
.single-post-header {
  padding: 3rem 0 1rem;
  text-align: center;
}

.single-post-header .post-categories {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  margin-bottom: 1rem;
}

.single-post-header .cat-link {
  background: var(--color-saffron-light);
  color: var(--color-terracotta);
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 0.25rem 0.7rem;
  border-radius: var(--radius);
}

.single-post-title {
  font-size: 2.4rem;
  max-width: 780px;
  margin: 0 auto 1rem;
  color: var(--color-text);
}

.single-post-meta {
  display: flex;
  justify-content: center;
  gap: 1.5rem;
  font-size: 0.88rem;
  color: var(--color-text-light);
  margin-bottom: 2rem;
}

.single-post-meta .meta-item {
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.single-post-meta svg {
  width: 16px;
  height: 16px;
  color: var(--color-saffron);
}

.single-featured-image {
  max-width: 900px;
  margin: 0 auto 2.5rem;
  border-radius: var(--radius);
  overflow: hidden;
}

.single-featured-image img {
  width: 100%;
  height: auto;
  display: block;
}

/* Post content */
.post-content {
  max-width: 760px;
  margin: 0 auto;
  font-size: 1.05rem;
  line-height: 1.8;
}

.post-content h2 {
  font-size: 1.7rem;
  margin: 2.2rem 0 0.8rem;
  color: var(--color-terracotta);
}

.post-content h3 {
  font-size: 1.35rem;
  margin: 1.8rem 0 0.7rem;
}

.post-content p {
  margin-bottom: 1.2em;
}

.post-content a {
  color: var(--color-terracotta);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.post-content a:hover {
  color: var(--color-terracotta-dark);
}

.post-content img {
  border-radius: var(--radius);
  margin: 1.5em 0;
}

.post-content blockquote {
  border-left: 4px solid var(--color-saffron);
  background: var(--color-saffron-light);
  padding: 1.2rem 1.5rem;
  margin: 1.5em 0;
  border-radius: 0 var(--radius) var(--radius) 0;
  font-style: italic;
  color: var(--color-text);
}

.post-content blockquote p:last-child {
  margin-bottom: 0;
}

/* Themed list bullets */
.post-content ul {
  list-style: none;
  padding-left: 0;
}

.post-content ul li {
  position: relative;
  padding-left: 1.8rem;
  margin-bottom: 0.6em;
}

.post-content ul li::before {
  content: '🍴';
  position: absolute;
  left: 0;
  top: 0;
  font-size: 0.85rem;
}

.post-content ul li:nth-child(3n+2)::before {
  content: '🥂';
}

.post-content ul li:nth-child(3n)::before {
  content: '🍽️';
}

.post-content ol {
  padding-left: 1.4em;
}

/* Checklist style */
.post-content .checklist,
.post-content ul.wp-block-list {
  list-style: none;
  padding-left: 0;
}

.post-content .checklist li {
  padding-left: 2rem;
}

.post-content .checklist li::before {
  content: '';
  width: 18px;
  height: 18px;
  border: 2px solid var(--color-saffron);
  border-radius: 50%;
  display: inline-block;
  position: absolute;
  left: 0;
  top: 3px;
}

/* Post tags */
.post-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 2.5rem 0;
  padding-top: 1.5rem;
  border-top: 1px solid var(--color-border);
}

.post-tags a {
  display: inline-block;
  padding: 0.3rem 0.85rem;
  background: transparent;
  border: 1.5px solid var(--color-terracotta);
  color: var(--color-terracotta);
  font-size: 0.82rem;
  font-weight: 600;
  border-radius: var(--radius);
  transition: background var(--transition), color var(--transition);
}

.post-tags a:hover {
  background: var(--color-terracotta);
  color: var(--color-white);
}

/* Post navigation */
.post-navigation {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
  margin: 2rem 0 3rem;
  padding: 1.5rem 0;
  border-top: 1px solid var(--color-border);
  border-bottom: 1px solid var(--color-border);
}

.post-navigation .nav-label {
  font-size: 0.78rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--color-text-light);
  margin-bottom: 0.3rem;
}

.post-navigation .nav-title {
  font-family: var(--font-display);
  font-size: 1rem;
  color: var(--color-text);
  transition: color var(--transition);
}

.post-navigation a:hover .nav-title {
  color: var(--color-terracotta);
}

.post-navigation .nav-next {
  text-align: right;
}

/* ========== PAGE TEMPLATE ========== */
.page-header-section {
  padding: 3rem 0 1rem;
  text-align: center;
}

.page-title {
  font-size: 2.2rem;
  color: var(--color-text);
}

.page-content {
  max-width: 760px;
  margin: 0 auto 3rem;
}

/* ========== COMMENTS ========== */
.comments-area {
  max-width: 760px;
  margin: 0 auto 3rem;
  padding-top: 2rem;
}

.comments-title {
  font-family: var(--font-display);
  font-size: 1.6rem;
  margin-bottom: 1.5rem;
  color: var(--color-text);
}

.comment-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.comment-list .comment {
  border-bottom: 1px solid var(--color-border);
  padding: 1.5rem 0;
}

.comment-list .children {
  list-style: none;
  margin-left: 2rem;
  padding: 0;
}

.comment-author {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  margin-bottom: 0.5rem;
}

.comment-author img {
  border-radius: 50%;
  width: 44px;
  height: 44px;
}

.comment-author .fn {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1rem;
  color: var(--color-text);
}

.comment-metadata {
  font-size: 0.8rem;
  color: var(--color-text-light);
  margin-bottom: 0.6rem;
}

.comment-content {
  font-size: 0.95rem;
  line-height: 1.7;
}

.comment-reply-link {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--color-terracotta);
}

/* Comment form */
.comment-respond {
  margin-top: 2rem;
}

.comment-respond .comment-reply-title {
  font-family: var(--font-display);
  font-size: 1.4rem;
  margin-bottom: 1rem;
}

.comment-form label {
  display: block;
  font-size: 0.88rem;
  font-weight: 600;
  margin-bottom: 0.3rem;
  color: var(--color-text);
}

.comment-form input[type="text"],
.comment-form input[type="email"],
.comment-form input[type="url"],
.comment-form textarea {
  width: 100%;
  padding: 0.65rem 1rem;
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  font-family: var(--font-body);
  font-size: 0.95rem;
  color: var(--color-text);
  background: var(--color-bg);
  transition: border-color var(--transition);
  margin-bottom: 1rem;
  outline: none;
}

.comment-form input:focus,
.comment-form textarea:focus {
  border-color: var(--color-terracotta);
}

.comment-form textarea {
  min-height: 140px;
  resize: vertical;
}

.comment-form .form-submit .submit {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.65rem 1.8rem;
  background: var(--color-terracotta);
  color: var(--color-white);
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.95rem;
  border: none;
  border-radius: var(--radius);
  cursor: pointer;
  transition: background var(--transition);
}

.comment-form .form-submit .submit:hover {
  background: var(--color-terracotta-dark);
}

/* ========== SEARCH FORM ========== */
.search-form {
  display: flex;
  gap: 0;
}

.search-form .search-field {
  flex: 1;
  padding: 0.65rem 1rem;
  border: 1px solid var(--color-border);
  border-right: none;
  border-radius: var(--radius) 0 0 var(--radius);
  font-family: var(--font-body);
  font-size: 0.95rem;
  color: var(--color-text);
  outline: none;
}

.search-form .search-field:focus {
  border-color: var(--color-terracotta);
}

.search-form .search-submit {
  padding: 0.65rem 1.2rem;
  background: var(--color-terracotta);
  color: var(--color-white);
  border: 1px solid var(--color-terracotta);
  border-radius: 0 var(--radius) var(--radius) 0;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.92rem;
  cursor: pointer;
  transition: background var(--transition);
}

.search-form .search-submit:hover {
  background: var(--color-terracotta-dark);
}

/* ========== SIDEBAR / WIDGETS ========== */
.widget {
  margin-bottom: 2rem;
}

.widget-title {
  font-family: var(--font-display);
  font-size: 1.15rem;
  margin-bottom: 0.8rem;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid var(--color-saffron);
  color: var(--color-text);
}

.widget ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

.widget ul li {
  padding: 0.45rem 0;
  border-bottom: 1px solid var(--color-border);
}

.widget ul li:last-child {
  border-bottom: none;
}

.widget ul li a {
  color: var(--color-text);
  font-size: 0.92rem;
}

.widget ul li a:hover {
  color: var(--color-terracotta);
}

/* ========== FOOTER ========== */
.site-footer {
  background: var(--color-bg-dark);
  color: #D4CBC3;
  padding: 3.5rem 0 0;
}

.footer-widgets {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2.5rem;
  padding-bottom: 2.5rem;
  border-bottom: 1px solid rgba(255,255,255,0.1);
}

.footer-widget-area .widget-title {
  color: var(--color-white);
  border-bottom-color: var(--color-terracotta);
  font-size: 1.1rem;
}

.footer-widget-area .widget ul li {
  border-bottom-color: rgba(255,255,255,0.08);
}

.footer-widget-area .widget ul li a {
  color: #D4CBC3;
}

.footer-widget-area .widget ul li a:hover {
  color: var(--color-saffron);
}

.footer-widget-area p,
.footer-widget-area {
  color: #D4CBC3;
}

/* Footer icon links */
.footer-icon-links {
  display: flex;
  gap: 2rem;
  margin-top: 1rem;
}

.footer-icon-link {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  color: #D4CBC3;
  font-size: 0.82rem;
  font-weight: 600;
  transition: color var(--transition);
}

.footer-icon-link:hover {
  color: var(--color-saffron);
}

.footer-icon-link svg {
  width: 36px;
  height: 36px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.5;
}

.footer-bottom {
  text-align: center;
  padding: 1.5rem 0;
  font-size: 0.88rem;
  color: #9B9189;
}

/* ========== 404 ========== */
.error-404 {
  text-align: center;
  padding: 5rem 0;
}

.error-404 h1 {
  font-size: 6rem;
  color: var(--color-saffron);
  line-height: 1;
  margin-bottom: 0.5rem;
}

.error-404 p {
  font-size: 1.1rem;
  color: var(--color-text-light);
  margin-bottom: 2rem;
}

/* ========== RESPONSIVE ========== */
@media (max-width: 960px) {
  .cards-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .cards-grid .card-article:first-child {
    grid-column: span 2;
  }

  .footer-widgets {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 768px) {
  :root {
    --gap: 1.2rem;
  }

  .header-inner {
    flex-wrap: wrap;
  }

  .menu-toggle {
    display: flex;
  }

  .main-navigation {
    display: none;
    width: 100%;
    order: 3;
  }

  .main-navigation.toggled {
    display: block;
  }

  .nav-menu {
    flex-direction: column;
    padding: 0.5rem 0;
  }

  .nav-menu .sub-menu {
    position: static;
    box-shadow: none;
    border: none;
    padding-left: 1rem;
    min-width: auto;
  }

  .nav-menu li:hover > .sub-menu {
    display: flex;
  }

  .header-search {
    order: 2;
  }

  .header-search .search-field {
    width: 160px;
  }

  .cards-grid {
    grid-template-columns: 1fr;
  }

  .cards-grid .card-article:first-child {
    grid-column: span 1;
  }

  .cards-grid .card-article:first-child .card-thumb {
    height: 220px;
  }

  .hero-title {
    font-size: 1.8rem;
  }

  .single-post-title {
    font-size: 1.7rem;
  }

  .post-navigation {
    grid-template-columns: 1fr;
  }

  .post-navigation .nav-next {
    text-align: left;
  }

  .footer-widgets {
    grid-template-columns: 1fr;
  }

  .author-box {
    flex-direction: column;
    text-align: center;
  }

  .single-post-meta {
    flex-direction: column;
    gap: 0.5rem;
  }
}

@media (max-width: 480px) {
  h1 { font-size: 1.8rem; }
  h2 { font-size: 1.5rem; }

  .hero-section {
    padding: 2.5rem 0 2rem;
  }

  .hero-description {
    font-size: 0.95rem;
  }

  .container {
    padding: 0 1rem;
  }
}
