/*
Theme Name:  Ynspir
Theme URI:   https://ynspir.com
Author:      Ynspir
Description: AI-powered home renovation visualization – WordPress theme.
Version:     2.0
Requires at least: 6.0
Tested up to: 6.4
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: ynspir
*/

/* ===========================
   DESIGN TOKENS
   =========================== */
:root {
  /* Colors — Material Design 3 palette */
  --primary: #002444;
  --on-primary: #ffffff;
  --primary-container: #1a3a5c;
  --on-primary-container: #87a4cc;
  --secondary: #924b1a;
  --on-secondary: #ffffff;
  --secondary-container: #fea36a;
  --on-secondary-container: #773704;
  --tertiary: #222424;
  --surface: #fcf8fb;
  --surface-dim: #dcd9dc;
  --surface-container-lowest: #ffffff;
  --surface-container-low: #f6f3f5;
  --surface-container: #f0edef;
  --surface-container-high: #eae7ea;
  --on-surface: #1b1b1d;
  --on-surface-variant: #43474e;
  --outline: #73777f;
  --outline-variant: #c3c6cf;
  --error: #ba1a1a;

  /* Font families */
  --font-headline: 'Manrope', sans-serif;
  --font-body: 'Inter', sans-serif;

  /* Radius */
  --radius-sm: 0.25rem;
  --radius-md: 0.5rem;
  --radius-lg: 0.75rem;
  --radius-xl: 1.5rem;
  --radius-full: 9999px;

  /* Shadows */
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.06);
  --shadow-md: 0 4px 12px rgba(0,0,0,0.08);
  --shadow-lg: 0 8px 24px rgba(0,0,0,0.1);
  --shadow-xl: 0 16px 48px rgba(0,0,0,0.12);
  --shadow-2xl: 0 24px 64px rgba(0,0,0,0.15);

  /* Max width */
  --max-width: 80rem;
}

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

a {
  text-decoration: none;
  color: inherit;
}

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

ul, ol {
  list-style: none;
}

/* ===========================
   BASE
   =========================== */
html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  background: var(--surface);
  color: var(--on-surface);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-headline);
  line-height: 1.15;
}

/* ===========================
   UTILITY CLASSES
   =========================== */
.text-accent { color: var(--secondary-container); }
.font-serif { font-style: italic; font-weight: 400; }

.glass-card {
  background: rgba(255,255,255,0.7);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}

/* Material Symbols */
.material-symbols-outlined {
  font-variation-settings: 'FILL' 0, 'wght' 400, 'GRAD' 0, 'opsz' 24;
}

/* ===========================
   ANIMATIONS
   =========================== */
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(30px); }
  to   { opacity: 1; transform: translateY(0); }
}

@keyframes fadeInLeft {
  from { opacity: 0; transform: translateX(-30px); }
  to   { opacity: 1; transform: translateX(0); }
}

@keyframes fadeInScale {
  from { opacity: 0; transform: scale(0.95); }
  to   { opacity: 1; transform: scale(1); }
}

.anim-fade-up {
  animation: fadeInUp 0.8s ease-out both;
}

.anim-fade-left {
  animation: fadeInLeft 0.8s ease-out both;
}

.anim-fade-scale {
  animation: fadeInScale 0.8s ease-out 0.2s both;
}

/* ===========================
   NAVBAR
   =========================== */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 50;
  background: rgba(255,255,255,0.7);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  box-shadow: var(--shadow-sm);
}

.navbar__inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 3rem;
  max-width: 100%;
}

.navbar__brand {
  font-size: 1.5rem;
  font-weight: 700;
  letter-spacing: -0.04em;
  color: var(--primary);
  font-family: var(--font-headline);
  font-style: italic;
}

.navbar__brand a {
  color: inherit;
}

.navbar__links {
  display: none;
  align-items: center;
  gap: 2rem;
}

.navbar__links ul {
  display: flex;
  align-items: center;
  gap: 2rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.navbar__links li {
  list-style: none;
}

.navbar__links li a {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--on-surface-variant);
  transition: color 0.3s;
  letter-spacing: 0.02em;
  font-family: var(--font-headline);
}

.navbar__links li a:hover,
.navbar__links li.current-menu-item a {
  color: var(--secondary);
  font-weight: 600;
}

.navbar__cta {
  background: linear-gradient(135deg, var(--secondary), var(--secondary-container));
  color: var(--on-secondary);
  padding: 0.5rem 1.5rem;
  border-radius: var(--radius-xl);
  font-family: var(--font-headline);
  font-weight: 700;
  font-size: 0.875rem;
  transition: opacity 0.2s, transform 0.2s;
  display: inline-block;
}

.navbar__cta:hover {
  opacity: 0.9;
}

.navbar__cta:active {
  transform: scale(0.95);
}

/* ===========================
   HERO SECTION
   =========================== */
.hero {
  position: relative;
  padding: 5rem 3rem;
  overflow: hidden;
  min-height: 870px;
  display: flex;
  align-items: center;
}

.hero__inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr;
  gap: 4rem;
  align-items: center;
}

.hero__content {
  z-index: 10;
}

.hero__badge {
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--secondary);
  display: block;
  margin-bottom: 1rem;
  font-family: var(--font-body);
}

.hero__title {
  font-size: 2.75rem;
  font-weight: 800;
  color: var(--primary);
  line-height: 1.1;
  margin-bottom: 2rem;
  font-family: var(--font-headline);
}

.hero__title .font-serif {
  font-weight: 400;
  font-style: italic;
}

.hero__subtitle {
  font-size: 1.125rem;
  color: var(--on-surface-variant);
  margin-bottom: 2.5rem;
  max-width: 32rem;
  line-height: 1.7;
}

.hero__actions {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.btn-primary {
  background: linear-gradient(135deg, var(--secondary), var(--secondary-container));
  color: var(--on-secondary);
  padding: 1rem 2rem;
  border-radius: var(--radius-xl);
  font-family: var(--font-headline);
  font-weight: 700;
  font-size: 1.125rem;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  box-shadow: var(--shadow-lg);
  transition: all 0.3s;
  text-align: center;
  justify-content: center;
}

.btn-primary:hover {
  box-shadow: var(--shadow-xl);
  transform: translateY(-1px);
}

.btn-secondary {
  background: var(--surface-container-lowest);
  color: var(--primary);
  padding: 1rem 2rem;
  border-radius: var(--radius-xl);
  font-family: var(--font-headline);
  font-weight: 700;
  font-size: 1.125rem;
  border: 2px solid rgba(0,36,68,0.05);
  transition: background 0.3s;
  text-align: center;
}

.btn-secondary:hover {
  background: var(--surface-container-low);
}

/* Hero Image */
.hero__image-wrapper {
  position: relative;
}

.hero__blob-1 {
  position: absolute;
  top: -2.5rem;
  left: -2.5rem;
  width: 16rem;
  height: 16rem;
  background: rgba(255,219,200,0.3);
  border-radius: var(--radius-full);
  filter: blur(60px);
  z-index: -1;
}

.hero__blob-2 {
  position: absolute;
  bottom: -2.5rem;
  right: -2.5rem;
  width: 16rem;
  height: 16rem;
  background: rgba(210,228,255,0.3);
  border-radius: var(--radius-full);
  filter: blur(60px);
  z-index: -1;
}

.hero__image-frame {
  position: relative;
  border-radius: var(--radius-xl);
  overflow: hidden;
  box-shadow: var(--shadow-2xl);
  transform: rotate(2deg);
  transition: transform 0.7s;
}

.hero__image-wrapper:hover .hero__image-frame {
  transform: rotate(0deg);
}

.hero__image-frame img {
  width: 100%;
  height: 500px;
  object-fit: cover;
}

.hero__image-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0,36,68,0.4), transparent);
}

.hero__floating-card {
  position: absolute;
  bottom: 2.5rem;
  left: -1rem;
  padding: 1.5rem;
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-xl);
  max-width: 18rem;
  transform: rotate(-3deg);
  z-index: 10;
}

.hero__floating-icon {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 0.5rem;
}

.hero__floating-icon .material-symbols-outlined {
  color: var(--secondary);
  font-variation-settings: 'FILL' 1;
}

.hero__floating-title {
  font-size: 0.875rem;
  font-weight: 700;
  color: var(--primary);
  font-family: var(--font-headline);
}

.hero__floating-text {
  font-size: 0.75rem;
  color: var(--on-surface-variant);
  line-height: 1.5;
}

/* ===========================
   CATEGORY GRID
   =========================== */
.categories {
  background: var(--surface-container-low);
  padding: 6rem 3rem;
}

.categories__inner {
  max-width: var(--max-width);
  margin: 0 auto;
}

.categories__header {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-bottom: 4rem;
}

.categories__badge {
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--secondary);
  font-family: var(--font-body);
}

.categories__title {
  font-size: 2.25rem;
  font-weight: 700;
  color: var(--primary);
}

.categories__subtitle {
  color: var(--on-surface-variant);
  max-width: 28rem;
}

.categories__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
}

.category-card {
  background: var(--surface-container-lowest);
  padding: 2rem;
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-sm);
  transition: box-shadow 0.3s, transform 0.3s;
}

.category-card:hover {
  box-shadow: var(--shadow-xl);
  transform: translateY(-2px);
}

.category-card__icon {
  width: 3.5rem;
  height: 3.5rem;
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.5rem;
  transition: transform 0.3s;
}

.category-card:hover .category-card__icon {
  transform: scale(1.1);
}

.category-card__icon--primary {
  background: rgba(0,36,68,0.05);
}

.category-card__icon--secondary {
  background: rgba(146,75,26,0.05);
}

.category-card__icon .material-symbols-outlined {
  font-size: 1.75rem;
}

.category-card__icon--primary .material-symbols-outlined {
  color: var(--primary);
}

.category-card__icon--secondary .material-symbols-outlined {
  color: var(--secondary);
}

.category-card__title {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--primary);
  margin-bottom: 0.75rem;
  font-family: var(--font-headline);
}

.category-card__text {
  font-size: 0.875rem;
  color: var(--on-surface-variant);
  line-height: 1.6;
}

/* ===========================
   BEFORE/AFTER SLIDER
   =========================== */
.slider-section {
  padding: 6rem 3rem;
  overflow: hidden;
}

.slider-section__inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 4rem;
}

.slider-section__content {
  flex: 1;
}

.slider-section__badge {
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--secondary);
  display: block;
  margin-bottom: 1rem;
}

.slider-section__title {
  font-size: 2.25rem;
  font-weight: 700;
  color: var(--primary);
  line-height: 1.15;
  margin-bottom: 2rem;
}

.slider-section__title .font-serif {
  font-weight: 400;
  font-style: italic;
}

.slider-section__steps {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  margin-bottom: 2.5rem;
}

.step {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
}

.step__number {
  width: 2rem;
  height: 2rem;
  border-radius: var(--radius-full);
  background: var(--secondary);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.875rem;
  flex-shrink: 0;
}

.step__title {
  font-weight: 700;
  color: var(--primary);
  margin-bottom: 0.25rem;
}

.step__text {
  font-size: 0.875rem;
  color: var(--on-surface-variant);
}

.btn-dark {
  background: var(--primary);
  color: white;
  padding: 1rem 2.5rem;
  border-radius: var(--radius-xl);
  font-family: var(--font-headline);
  font-weight: 700;
  font-size: 1.125rem;
  transition: background 0.3s;
  display: inline-block;
}

.btn-dark:hover {
  background: rgba(0,36,68,0.9);
}

/* Slider visual */
.slider-section__visual {
  flex: 1;
  position: relative;
}

.slider-frame {
  position: relative;
  aspect-ratio: 16/10;
  border-radius: var(--radius-xl);
  overflow: hidden;
  box-shadow: var(--shadow-2xl);
  border: 8px solid var(--surface-container-lowest);
  --slider-pos: 50%;
}

.slider-frame__after {
  position: absolute;
  inset: 0;
}

.slider-frame__after img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.slider-frame__before {
  position: absolute;
  inset: 0;
  width: 100%;
  clip-path: polygon(0 0, var(--slider-pos) 0, var(--slider-pos) 100%, 0 100%);
}

.slider-frame__before img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: grayscale(1) brightness(0.75);
}

.slider-handle {
  position: absolute;
  left: var(--slider-pos);
  top: 0;
  bottom: 0;
  width: 4px;
  background: white;
  display: flex;
  align-items: center;
  justify-content: center;
  transform: translateX(-50%);
  pointer-events: none;
  z-index: 2;
}

.slider-handle__knob {
  width: 3rem;
  height: 3rem;
  border-radius: var(--radius-full);
  background: var(--surface-container-lowest);
  box-shadow: var(--shadow-2xl);
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
}

.slider-handle__knob .material-symbols-outlined {
  color: var(--primary);
}

.slider-range {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  cursor: ew-resize;
  z-index: 5;
  margin: 0;
  -webkit-appearance: none;
  appearance: none;
  background: transparent;
}

.slider-label {
  position: absolute;
  bottom: 1rem;
  padding: 0.25rem 0.75rem;
  border-radius: var(--radius-md);
  font-size: 0.625rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--primary);
  pointer-events: none;
  z-index: 2;
}

.slider-label--before { left: 1rem; }
.slider-label--after  { right: 1rem; }

/* ===========================
   TESTIMONIALS
   =========================== */
.testimonials {
  background: var(--surface);
  padding: 6rem 3rem;
}

.testimonials__inner {
  max-width: var(--max-width);
  margin: 0 auto;
}

.testimonials__title {
  font-size: 2.25rem;
  font-weight: 700;
  color: var(--primary);
  text-align: center;
  margin-bottom: 4rem;
}

.testimonials__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
}

/* Featured testimonial (large) */
.testimonial-featured {
  background: var(--primary-container);
  padding: 3rem;
  border-radius: var(--radius-xl);
  color: var(--on-primary-container);
  position: relative;
  overflow: hidden;
}

.testimonial-featured__quote-icon {
  font-size: 3rem;
  color: var(--secondary-container);
  margin-bottom: 1.5rem;
  font-variation-settings: 'FILL' 1;
}

.testimonial-featured__text {
  font-size: 1.375rem;
  font-family: var(--font-headline);
  line-height: 1.6;
  font-style: italic;
  margin-bottom: 2rem;
}

.testimonial-featured__author {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.testimonial-featured__avatar {
  width: 3rem;
  height: 3rem;
  border-radius: var(--radius-full);
  background: rgba(135,164,204,0.2);
  object-fit: cover;
}

.testimonial-featured__name {
  font-weight: 700;
}

.testimonial-featured__role {
  font-size: 0.875rem;
  opacity: 0.7;
}

.testimonial-featured__deco {
  position: absolute;
  top: 0;
  right: 0;
  width: 16rem;
  height: 100%;
  background: var(--secondary-container);
  opacity: 0.1;
  transform: rotate(-12deg) translateX(6rem);
}

/* Small testimonial card */
.testimonial-card {
  background: var(--surface-container-lowest);
  padding: 2.5rem;
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-sm);
  border: 1px solid rgba(0,36,68,0.05);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.testimonial-card__stars {
  display: flex;
  gap: 2px;
  color: var(--secondary-container);
  margin-bottom: 1.5rem;
}

.testimonial-card__stars .material-symbols-outlined {
  font-size: 1.25rem;
  font-variation-settings: 'FILL' 1;
}

.testimonial-card__quote {
  color: var(--on-surface-variant);
  font-weight: 500;
  line-height: 1.7;
  margin-bottom: 2rem;
}

.testimonial-card__name {
  font-weight: 700;
  color: var(--primary);
}

.testimonial-card__role {
  font-size: 0.75rem;
  color: var(--on-surface-variant);
}

/* ===========================
   CTA SECTION
   =========================== */
.cta {
  padding: 6rem 3rem;
}

.cta__box {
  max-width: var(--max-width);
  margin: 0 auto;
  background: linear-gradient(135deg, var(--primary), var(--primary-container));
  border-radius: 1.5rem;
  padding: 4rem 3rem;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.cta__blob-1 {
  position: absolute;
  bottom: -6rem;
  left: -6rem;
  width: 24rem;
  height: 24rem;
  background: var(--secondary);
  opacity: 0.2;
  border-radius: var(--radius-full);
  filter: blur(100px);
}

.cta__blob-2 {
  position: absolute;
  top: -6rem;
  right: -6rem;
  width: 24rem;
  height: 24rem;
  background: var(--on-primary-container);
  opacity: 0.2;
  border-radius: var(--radius-full);
  filter: blur(100px);
}

.cta__content {
  position: relative;
  z-index: 10;
}

.cta__title {
  font-size: 2.25rem;
  font-weight: 800;
  color: white;
  line-height: 1.15;
  margin-bottom: 2rem;
  font-family: var(--font-headline);
}

.cta__title .text-accent {
  color: var(--secondary-container);
  font-style: italic;
  font-weight: 400;
}

.cta__subtitle {
  color: rgba(255,255,255,0.7);
  font-size: 1.125rem;
  max-width: 40rem;
  margin: 0 auto 3rem;
}

.btn-cta {
  background: var(--secondary);
  color: white;
  padding: 1.25rem 3rem;
  border-radius: var(--radius-xl);
  font-family: var(--font-headline);
  font-weight: 700;
  font-size: 1.25rem;
  box-shadow: var(--shadow-2xl);
  transition: background 0.3s;
  display: inline-block;
}

.btn-cta:hover {
  background: var(--secondary-container);
}

/* ===========================
   FOOTER
   =========================== */
.footer {
  background: var(--surface-container-low);
  border-top: 1px solid rgba(0,0,0,0.03);
  margin-top: 5rem;
}

.footer__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
  padding: 4rem 3rem;
  max-width: var(--max-width);
  margin: 0 auto;
  font-size: 0.875rem;
}

.footer__brand-name {
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--primary);
  font-family: var(--font-headline);
  margin-bottom: 1.5rem;
}

.footer__brand-text {
  color: var(--on-surface-variant);
  line-height: 1.7;
  margin-bottom: 1.5rem;
}

.footer__social {
  display: flex;
  gap: 1rem;
}

.footer__social .material-symbols-outlined {
  color: var(--primary);
  font-size: 1.5rem;
}

.footer__heading {
  color: var(--primary);
  font-weight: 700;
  margin-bottom: 1.5rem;
  font-family: var(--font-headline);
}

.footer__links {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.footer__links a {
  color: var(--on-surface-variant);
  transition: color 0.2s;
}

.footer__links a:hover {
  color: var(--primary);
  text-decoration: underline;
}

/* WordPress menu reset in footer */
.footer__links ul {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.footer__links li {
  list-style: none;
}

.footer__newsletter-text {
  color: var(--on-surface-variant);
  margin-bottom: 1rem;
  line-height: 1.6;
}

.footer__newsletter-form {
  display: flex;
}

.footer__newsletter-input {
  flex: 1;
  padding: 0.625rem 1rem;
  border: 1px solid var(--outline-variant);
  border-right: none;
  border-radius: var(--radius-md) 0 0 var(--radius-md);
  background: white;
  font-family: var(--font-body);
  font-size: 0.875rem;
  outline: none;
}

.footer__newsletter-input:focus {
  border-color: var(--secondary-container);
}

.footer__newsletter-btn {
  background: var(--primary);
  color: white;
  padding: 0.625rem 1rem;
  border: none;
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
  cursor: pointer;
  display: flex;
  align-items: center;
}

.footer__newsletter-btn:hover {
  background: var(--primary-container);
}

.footer__bottom {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 2rem 3rem;
  border-top: 1px solid rgba(0,0,0,0.06);
  text-align: center;
}

.footer__copy {
  font-size: 0.75rem;
  color: var(--on-surface-variant);
}

/* ===========================
   RESPONSIVE
   =========================== */
@media (min-width: 768px) {
  .navbar__links {
    display: flex;
  }

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

  .hero__title {
    font-size: 3.5rem;
  }

  .hero__actions {
    flex-direction: row;
  }

  .hero__image-frame img {
    height: 600px;
  }

  .hero__floating-card {
    left: -3rem;
  }

  .categories__header {
    flex-direction: row;
    justify-content: space-between;
    align-items: flex-end;
  }

  .categories__grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .slider-section__inner {
    flex-direction: row;
    align-items: center;
  }

  .slider-section__content {
    width: 50%;
  }

  .slider-section__visual {
    width: 50%;
  }

  .slider-section__title {
    font-size: 2.75rem;
  }

  .testimonials__grid {
    grid-template-columns: 2fr 1fr;
  }

  .testimonials__title {
    font-size: 2.5rem;
  }

  .cta__box {
    padding: 4rem;
  }

  .cta__title {
    font-size: 3.5rem;
  }

  .footer__grid {
    grid-template-columns: 1.5fr 1fr 1fr 1.5fr;
  }
}

@media (min-width: 1024px) {
  .hero__title {
    font-size: 4.25rem;
  }

  .categories__grid {
    grid-template-columns: repeat(4, 1fr);
  }

  .cta__title {
    font-size: 3.75rem;
  }
}

/* WordPress admin bar fix */
body.admin-bar .navbar {
  top: 32px;
}

@media screen and (max-width: 782px) {
  body.admin-bar .navbar {
    top: 46px;
  }
}

/* ===========================
   ELEMENTOR COMPATIBILITY
   =========================== */
.elementor-full-width-content {
  width: 100%;
  max-width: 100%;
  padding: 0;
  margin: 0;
}

.elementor-section.elementor-section-stretched {
  width: 100vw !important;
  margin-left: calc(-50vw + 50%) !important;
}

body.elementor-canvas .site-main {
  padding-top: 0 !important;
}

.elementor-page .site-main {
  padding-top: 4rem;
}

/* ===========================
   PAGE HERO
   =========================== */
.page-hero {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-container) 100%);
  padding: 10rem 3rem 4rem;
  position: relative;
  overflow: hidden;
}

.page-hero::before {
  content: '';
  position: absolute;
  top: -6rem;
  right: -6rem;
  width: 24rem;
  height: 24rem;
  background: var(--secondary-container);
  opacity: 0.12;
  border-radius: var(--radius-full);
  filter: blur(100px);
}

.page-hero::after {
  content: '';
  position: absolute;
  bottom: -4rem;
  left: -4rem;
  width: 16rem;
  height: 16rem;
  background: var(--on-primary-container);
  opacity: 0.1;
  border-radius: var(--radius-full);
  filter: blur(80px);
}

.page-hero__inner {
  max-width: var(--max-width);
  margin: 0 auto;
  position: relative;
  z-index: 1;
}

.page-hero__title {
  font-family: var(--font-headline);
  font-size: 2.5rem;
  font-weight: 800;
  color: white;
  line-height: 1.15;
  margin-bottom: 1rem;
}

.page-hero__subtitle {
  font-size: 1.125rem;
  color: rgba(255,255,255,0.7);
  max-width: 40rem;
  line-height: 1.7;
}

@media (min-width: 768px) {
  .page-hero__title { font-size: 3.25rem; }
}

/* ===========================
   PAGE CONTENT
   =========================== */
.page-content {
  padding: 0 3rem 6rem;
  margin-top: -2rem;
  position: relative;
  z-index: 2;
}

.page-content__inner {
  max-width: 48rem;
  margin: 0 auto;
}

.page-content__card {
  background: rgba(255,255,255,0.85);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-lg);
  padding: 3rem 2rem;
  border: 1px solid rgba(0,36,68,0.04);
}

@media (min-width: 768px) {
  .page-content__card { padding: 4rem 5rem; }
}

@media (min-width: 1024px) {
  .page-content__card { padding: 4.5rem 6rem; }
}

/* ===========================
   ENTRY CONTENT – Prose
   =========================== */
.entry-content {
  line-height: 1.8;
  color: var(--on-surface);
  font-size: 0.9375rem;
}

/* Headings */
.entry-content h1 {
  font-size: 2rem;
  font-weight: 800;
  color: var(--primary);
  margin: 2.5rem 0 1rem;
  font-family: var(--font-headline);
  line-height: 1.2;
}

.entry-content h2 {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--primary);
  margin: 2.25rem 0 0.875rem;
  font-family: var(--font-headline);
  padding-bottom: 0.5rem;
  border-bottom: 2px solid var(--outline-variant);
}

.entry-content h3 {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--primary);
  margin: 2rem 0 0.75rem;
  font-family: var(--font-headline);
}

.entry-content h4, .entry-content h5, .entry-content h6 {
  font-size: 1.0625rem;
  font-weight: 700;
  color: var(--primary);
  margin: 1.75rem 0 0.5rem;
  font-family: var(--font-headline);
}

/* First heading — no top margin */
.entry-content > h1:first-child,
.entry-content > h2:first-child,
.entry-content > h3:first-child {
  margin-top: 0;
}

/* Paragraphs */
.entry-content p {
  margin-bottom: 1.25rem;
  color: var(--on-surface-variant);
}

/* Strong & emphasis */
.entry-content strong {
  font-weight: 700;
  color: var(--on-surface);
}

.entry-content em {
  font-style: italic;
}

/* Links */
.entry-content a {
  color: var(--secondary);
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-thickness: 1px;
  transition: color 0.2s, text-decoration-color 0.2s;
}

.entry-content a:hover {
  color: var(--secondary-container);
  text-decoration-color: var(--secondary-container);
}

/* Lists */
.entry-content ul,
.entry-content ol {
  margin: 1rem 0 1.5rem 1.5rem;
  color: var(--on-surface-variant);
}

.entry-content ul {
  list-style: disc;
}

.entry-content ol {
  list-style: decimal;
}

.entry-content li {
  margin-bottom: 0.5rem;
  padding-left: 0.25rem;
  list-style: inherit;
}

.entry-content li::marker {
  color: var(--secondary);
}

/* Blockquote */
.entry-content blockquote {
  margin: 2rem 0;
  padding: 1.5rem 2rem;
  background: var(--surface-container-low);
  border-left: 4px solid var(--secondary);
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
  font-style: italic;
  color: var(--on-surface-variant);
}

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

/* Horizontal rule */
.entry-content hr {
  border: none;
  height: 1px;
  background: var(--outline-variant);
  margin: 2.5rem 0;
}

/* Images */
.entry-content img {
  border-radius: var(--radius-lg);
  margin: 2rem 0;
  box-shadow: var(--shadow-md);
}

/* Tables */
.entry-content table {
  width: 100%;
  border-collapse: collapse;
  margin: 2rem 0;
  font-size: 0.875rem;
}

.entry-content th {
  background: var(--surface-container-high);
  color: var(--primary);
  font-weight: 700;
  font-family: var(--font-headline);
  padding: 0.75rem 1rem;
  text-align: left;
  border-bottom: 2px solid var(--outline-variant);
}

.entry-content td {
  padding: 0.75rem 1rem;
  border-bottom: 1px solid var(--outline-variant);
  color: var(--on-surface-variant);
}

.entry-content tr:last-child td {
  border-bottom: none;
}

/* Code */
.entry-content code {
  background: var(--surface-container);
  padding: 0.15em 0.4em;
  border-radius: var(--radius-sm);
  font-size: 0.85em;
  font-family: 'Fira Code', 'Courier New', monospace;
}

.entry-content pre {
  background: var(--surface-container);
  padding: 1.25rem 1.5rem;
  border-radius: var(--radius-md);
  overflow-x: auto;
  margin: 2rem 0;
}

.entry-content pre code {
  background: none;
  padding: 0;
}
