/* =========================================
   Fairmontis.eu – Family Home Ideas
   Warm, soft, lifestyle-focused stylesheet
   ========================================= */

:root {
  --bg: #FBF7F2;
  --bg-soft: #F4ECE2;
  --surface: #FFFFFF;
  --text: #2E2A26;
  --text-muted: #6B6258;
  --accent: #C97B5A;        /* warm terracotta */
  --accent-dark: #A85F3F;
  --accent-soft: #F0D7C8;
  --sage: #8FA68E;          /* soft sage green */
  --sage-soft: #DDE5DA;
  --cream: #F7E9D7;
  --border: #EADFD2;
  --shadow: 0 6px 24px rgba(62, 44, 32, 0.08);
  --radius: 14px;
  --radius-lg: 22px;
  --max-w: 1180px;
  --transition: 0.25s ease;
  --font-sans: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  --font-serif: 'Playfair Display', Georgia, 'Times New Roman', serif;
}

/* ---------- Reset ---------- */
*,
*::before,
*::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.65;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

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

h1, h2, h3, h4 {
  font-family: var(--font-serif);
  color: var(--text);
  margin: 0 0 0.6em;
  line-height: 1.25;
  font-weight: 600;
}
h1 { font-size: clamp(2rem, 4vw, 3.2rem); }
h2 { font-size: clamp(1.6rem, 3vw, 2.3rem); }
h3 { font-size: 1.3rem; }

p { margin: 0 0 1em; }

.container {
  width: 100%;
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 24px;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-block;
  padding: 13px 26px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.95rem;
  letter-spacing: 0.2px;
  cursor: pointer;
  border: none;
  transition: all var(--transition);
  text-align: center;
}
.btn-primary {
  background: var(--accent);
  color: #fff;
}
.btn-primary:hover {
  background: var(--accent-dark);
  color: #fff;
  transform: translateY(-2px);
  box-shadow: 0 8px 18px rgba(168, 95, 63, 0.25);
}
.btn-outline {
  background: transparent;
  color: var(--accent-dark);
  border: 2px solid var(--accent);
}
.btn-outline:hover {
  background: var(--accent);
  color: #fff;
}

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(251, 247, 242, 0.92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}
.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 0;
}
.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-serif);
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--text);
}
.logo svg { width: 32px; height: 32px; }
.logo span em { color: var(--accent); font-style: normal; }

.nav-list {
  display: flex;
  gap: 28px;
  list-style: none;
  margin: 0;
  padding: 0;
}
.nav-list a {
  color: var(--text);
  font-weight: 500;
  font-size: 0.95rem;
  position: relative;
}
.nav-list a:hover,
.nav-list a.active { color: var(--accent-dark); }
.nav-list a.active::after {
  content: '';
  position: absolute;
  left: 0; right: 0;
  bottom: -6px;
  height: 2px;
  background: var(--accent);
  border-radius: 2px;
}

.nav-toggle {
  display: none;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 6px;
}
.nav-toggle span {
  display: block;
  width: 24px; height: 2px;
  background: var(--text);
  margin: 5px 0;
  transition: var(--transition);
}

/* ---------- Hero ---------- */
.hero {
  padding: 80px 0 60px;
  background: linear-gradient(135deg, var(--cream) 0%, var(--bg-soft) 100%);
  position: relative;
  overflow: hidden;
}
.hero-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
}
.hero-eyebrow {
  display: inline-block;
  font-size: 0.85rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--accent-dark);
  background: var(--accent-soft);
  padding: 6px 14px;
  border-radius: 999px;
  margin-bottom: 22px;
}
.hero h1 { margin-bottom: 18px; }
.hero p.lead {
  font-size: 1.12rem;
  color: var(--text-muted);
  margin-bottom: 28px;
  max-width: 520px;
}
.hero-cta { display: flex; gap: 14px; flex-wrap: wrap; }

.hero-image {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow);
  aspect-ratio: 4 / 5;
}
.hero-image img {
  width: 100%; height: 100%;
  object-fit: cover;
}
.hero-badge {
  position: absolute;
  bottom: 22px; left: 22px;
  background: rgba(255, 255, 255, 0.95);
  padding: 14px 18px;
  border-radius: 12px;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text);
  box-shadow: 0 4px 14px rgba(0,0,0,0.08);
}
.hero-badge strong { color: var(--accent-dark); }

/* ---------- Page Header (interior) ---------- */
.page-header {
  padding: 70px 0 40px;
  background: linear-gradient(135deg, var(--cream) 0%, var(--bg-soft) 100%);
  text-align: center;
}
.page-header h1 { margin-bottom: 12px; }
.page-header p {
  color: var(--text-muted);
  max-width: 640px;
  margin: 0 auto;
  font-size: 1.05rem;
}

/* ---------- Sections ---------- */
.section { padding: 70px 0; }
.section-alt { background: var(--bg-soft); }

.section-head {
  text-align: center;
  max-width: 680px;
  margin: 0 auto 50px;
}
.section-head .eyebrow {
  display: inline-block;
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--accent-dark);
  margin-bottom: 12px;
}
.section-head p { color: var(--text-muted); }

/* ---------- Categories ---------- */
.categories {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 22px;
}
.category-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px 22px;
  text-align: center;
  transition: all var(--transition);
  display: block;
  color: var(--text);
}
.category-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow);
  border-color: var(--accent-soft);
  color: var(--text);
}
.category-icon {
  width: 56px; height: 56px;
  margin: 0 auto 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--accent-soft);
  border-radius: 50%;
  color: var(--accent-dark);
}
.category-card.cat-edu .category-icon { background: var(--sage-soft); color: #4a6b4a; }
.category-card.cat-soc .category-icon { background: #F4DCD0; color: #9c5236; }
.category-card.cat-tech .category-icon { background: #E4DBEA; color: #6b5588; }

.category-card h3 { font-size: 1.15rem; margin-bottom: 6px; }
.category-card p {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin: 0;
}

/* ---------- Article cards ---------- */
.articles-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
}
.article-card {
  background: var(--surface);
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border);
  transition: all var(--transition);
  display: flex;
  flex-direction: column;
}
.article-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow);
}
.article-thumb {
  aspect-ratio: 16 / 10;
  overflow: hidden;
}
.article-thumb img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}
.article-card:hover .article-thumb img { transform: scale(1.05); }
.article-body {
  padding: 22px 22px 24px;
  flex: 1;
  display: flex;
  flex-direction: column;
}
.article-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-bottom: 10px;
}
.article-tag {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  padding: 4px 10px;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent-dark);
}
.article-tag.tag-edu { background: var(--sage-soft); color: #4a6b4a; }
.article-tag.tag-soc { background: #F4DCD0; color: #9c5236; }
.article-tag.tag-tech { background: #E4DBEA; color: #6b5588; }

.article-card h3 {
  font-size: 1.18rem;
  margin-bottom: 10px;
}
.article-card h3 a { color: var(--text); }
.article-card h3 a:hover { color: var(--accent-dark); }
.article-card p {
  color: var(--text-muted);
  font-size: 0.95rem;
  margin-bottom: 16px;
  flex: 1;
}
.article-link {
  font-weight: 600;
  font-size: 0.92rem;
  color: var(--accent-dark);
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.article-link:hover { gap: 10px; }

/* ---------- Latest articles feed (list style) ---------- */
.feed {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 22px;
}
.feed-item {
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: 18px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 14px;
  transition: all var(--transition);
}
.feed-item:hover { box-shadow: var(--shadow); border-color: var(--accent-soft); }
.feed-thumb {
  aspect-ratio: 1;
  border-radius: 10px;
  overflow: hidden;
}
.feed-thumb img { width: 100%; height: 100%; object-fit: cover; }
.feed-content h4 {
  font-size: 1.02rem;
  margin: 6px 0 8px;
  font-family: var(--font-serif);
  font-weight: 600;
}
.feed-content h4 a { color: var(--text); }
.feed-content h4 a:hover { color: var(--accent-dark); }
.feed-content .article-meta { margin-bottom: 6px; }
.feed-content p {
  font-size: 0.88rem;
  color: var(--text-muted);
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* ---------- About ---------- */
.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
}
.about-image {
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow);
  aspect-ratio: 4/3;
}
.about-image img { width: 100%; height: 100%; object-fit: cover; }
.about-values {
  list-style: none;
  margin: 24px 0 0;
  padding: 0;
  display: grid;
  gap: 14px;
}
.about-values li {
  display: flex;
  gap: 14px;
  align-items: flex-start;
}
.about-values .check {
  flex-shrink: 0;
  width: 28px; height: 28px;
  border-radius: 50%;
  background: var(--accent-soft);
  color: var(--accent-dark);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.9rem;
}
.about-values strong { display: block; margin-bottom: 2px; color: var(--text); }
.about-values span.desc { color: var(--text-muted); font-size: 0.95rem; }

/* ---------- Stats / Highlights ---------- */
.highlights {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
  margin-top: 50px;
}
.highlight {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 26px;
  text-align: center;
}
.highlight .num {
  font-family: var(--font-serif);
  font-size: 2.2rem;
  color: var(--accent-dark);
  font-weight: 700;
  display: block;
  margin-bottom: 4px;
}
.highlight p {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.95rem;
}

/* ---------- Contact form ---------- */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: 50px;
}
.contact-info {
  background: var(--bg-soft);
  border-radius: var(--radius-lg);
  padding: 36px 32px;
}
.contact-info h3 { margin-top: 0; }
.contact-info ul {
  list-style: none;
  padding: 0;
  margin: 24px 0 0;
  display: grid;
  gap: 18px;
}
.contact-info li {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  font-size: 0.95rem;
  color: var(--text-muted);
}
.contact-info li strong { display: block; color: var(--text); margin-bottom: 2px; }
.contact-info .icon-circle {
  flex-shrink: 0;
  width: 38px; height: 38px;
  border-radius: 50%;
  background: var(--accent-soft);
  color: var(--accent-dark);
  display: flex;
  align-items: center;
  justify-content: center;
}

.contact-form {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 36px 32px;
}
.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
}
.form-group {
  margin-bottom: 18px;
}
.form-group label {
  display: block;
  font-weight: 500;
  font-size: 0.92rem;
  margin-bottom: 6px;
  color: var(--text);
}
.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--bg);
  font-family: inherit;
  font-size: 0.95rem;
  color: var(--text);
  transition: border-color var(--transition), box-shadow var(--transition);
}
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(201, 123, 90, 0.15);
}
.form-group textarea { min-height: 130px; resize: vertical; }

.form-check {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  font-size: 0.88rem;
  color: var(--text-muted);
  margin-bottom: 18px;
}
.form-check input { margin-top: 4px; }
.form-message {
  display: none;
  padding: 14px 16px;
  border-radius: 10px;
  margin-bottom: 16px;
  font-size: 0.92rem;
}
.form-message.success {
  background: var(--sage-soft);
  color: #3e5a3e;
  border: 1px solid #b6c8b6;
  display: block;
}
.form-message.error {
  background: #f8d7da;
  color: #842029;
  border: 1px solid #f1aeb5;
  display: block;
}

/* ---------- Newsletter / CTA banner ---------- */
.cta-banner {
  background: linear-gradient(135deg, var(--accent-soft) 0%, var(--cream) 100%);
  border-radius: var(--radius-lg);
  padding: 50px 40px;
  text-align: center;
}
.cta-banner h2 { margin-bottom: 10px; }
.cta-banner p { color: var(--text-muted); max-width: 560px; margin: 0 auto 24px; }

/* ---------- Article (single-style) ---------- */
.legal-content {
  max-width: 820px;
  margin: 0 auto;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 44px 40px;
}
.legal-content h2 { margin-top: 32px; }
.legal-content h2:first-child { margin-top: 0; }
.legal-content ul { padding-left: 22px; }
.legal-content li { margin-bottom: 8px; color: var(--text-muted); }
.legal-content p { color: var(--text-muted); }

/* ---------- Footer ---------- */
.site-footer {
  background: #2E2A26;
  color: #D9CFC2;
  padding: 60px 0 24px;
  margin-top: 40px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 40px;
  margin-bottom: 40px;
}
.footer-grid h4 {
  color: #fff;
  font-family: var(--font-sans);
  font-size: 0.95rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 18px;
}
.footer-grid p { color: #B8AB99; font-size: 0.92rem; }
.footer-grid ul { list-style: none; padding: 0; margin: 0; }
.footer-grid li { margin-bottom: 10px; font-size: 0.92rem; }
.footer-grid a { color: #D9CFC2; }
.footer-grid a:hover { color: var(--accent-soft); }

.footer-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-serif);
  font-size: 1.4rem;
  color: #fff;
  font-weight: 700;
  margin-bottom: 16px;
}
.footer-logo svg { width: 30px; height: 30px; }

.footer-bottom {
  border-top: 1px solid #3F3A34;
  padding-top: 22px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  font-size: 0.85rem;
  color: #B8AB99;
}

/* ---------- Cookie banner ---------- */
.cookie-banner {
  position: fixed;
  bottom: 20px; left: 20px; right: 20px;
  max-width: 720px;
  margin: 0 auto;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px 24px;
  box-shadow: 0 12px 32px rgba(0,0,0,0.18);
  z-index: 200;
  display: none;
  animation: slideUp 0.35s ease;
}
.cookie-banner.show { display: block; }
.cookie-banner h4 {
  font-family: var(--font-serif);
  margin: 0 0 8px;
  font-size: 1.15rem;
}
.cookie-banner p {
  margin: 0 0 16px;
  font-size: 0.9rem;
  color: var(--text-muted);
}
.cookie-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}
.cookie-actions .btn { padding: 10px 18px; font-size: 0.88rem; }
.cookie-actions a {
  align-self: center;
  font-size: 0.88rem;
}

/* Cookie preferences modal */
.cookie-modal {
  position: fixed;
  inset: 0;
  background: rgba(46, 42, 38, 0.5);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 300;
  padding: 20px;
}
.cookie-modal.show { display: flex; }
.cookie-modal-inner {
  background: var(--surface);
  border-radius: var(--radius);
  padding: 32px;
  max-width: 540px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 18px 60px rgba(0,0,0,0.25);
}
.cookie-modal-inner h3 { margin-top: 0; }
.cookie-toggle {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 0;
  border-bottom: 1px solid var(--border);
}
.cookie-toggle:last-of-type { border-bottom: none; }
.cookie-toggle strong { display: block; margin-bottom: 2px; }
.cookie-toggle small { color: var(--text-muted); font-size: 0.85rem; }

/* simple toggle switch */
.switch { position: relative; display: inline-block; width: 44px; height: 24px; flex-shrink: 0; }
.switch input { opacity: 0; width: 0; height: 0; }
.slider {
  position: absolute; cursor: pointer;
  inset: 0;
  background-color: #d8cfc3;
  border-radius: 24px;
  transition: 0.3s;
}
.slider::before {
  content: '';
  position: absolute;
  height: 18px; width: 18px;
  left: 3px; bottom: 3px;
  background: #fff;
  border-radius: 50%;
  transition: 0.3s;
}
.switch input:checked + .slider { background-color: var(--accent); }
.switch input:checked + .slider::before { transform: translateX(20px); }
.switch input:disabled + .slider { opacity: 0.55; cursor: not-allowed; }

.cookie-modal-actions {
  display: flex;
  gap: 10px;
  margin-top: 22px;
  flex-wrap: wrap;
}

@keyframes slideUp {
  from { transform: translateY(20px); opacity: 0; }
  to   { transform: translateY(0); opacity: 1; }
}

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
  .hero-grid,
  .about-grid,
  .contact-grid { grid-template-columns: 1fr; gap: 40px; }
  .categories { grid-template-columns: repeat(2, 1fr); }
  .articles-grid { grid-template-columns: repeat(2, 1fr); }
  .feed { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .highlights { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .nav-list {
    position: absolute;
    top: 100%; left: 0; right: 0;
    background: var(--surface);
    flex-direction: column;
    gap: 0;
    padding: 12px 24px 18px;
    border-bottom: 1px solid var(--border);
    display: none;
    box-shadow: 0 8px 18px rgba(0,0,0,0.06);
  }
  .nav-list.open { display: flex; }
  .nav-list li { padding: 10px 0; border-bottom: 1px solid var(--border); }
  .nav-list li:last-child { border-bottom: none; }
  .nav-toggle { display: block; }

  .articles-grid { grid-template-columns: 1fr; }
  .form-row { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; gap: 28px; }
  .legal-content { padding: 28px 22px; }
  .feed-item { grid-template-columns: 110px 1fr; }
  .section { padding: 50px 0; }
  .hero { padding: 50px 0 40px; }
  .cookie-banner { left: 10px; right: 10px; bottom: 10px; padding: 18px; }
}
