/* css/style.css — Planul B v2 */

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

:root {
  --antracit:       #1e1e1e;
  --antracit-light: #2d2d2d;
  --antracit-mid:   #3a3a3a;
  --portocaliu:     #ff6b35;
  --portocaliu-dk:  #e85a28;
  --portocaliu-xl:  #ff8c5a;
  --alb:            #ffffff;
  --gri-bg:         #f5f5f3;
  --gri-card:       #fafafa;
  --gri-border:     #e8e8e6;
  --gri-text:       #666660;
  --text-main:      #1e1e1e;
  --green:          #2d7a4f;
  --blue:           #1a5fa8;

  --font: 'Montserrat', sans-serif;
  --shadow-sm: 0 2px 8px rgba(0,0,0,.06);
  --shadow-md: 0 4px 20px rgba(0,0,0,.10);
  --shadow-lg: 0 8px 32px rgba(0,0,0,.14);
  --radius:    12px;
  --radius-sm: 8px;
  --max-w:     1200px;
}

html { scroll-behavior: smooth; font-size: 16px; }
body { font-family: var(--font); color: var(--text-main); background: var(--alb); line-height: 1.6; }
img  { max-width: 100%; display: block; }
a    { color: inherit; text-decoration: none; }

/* ── UTILITIES ─────────────────────────────────────────────── */
.container   { max-width: var(--max-w); margin: 0 auto; padding: 0 1.5rem; }
.section     { padding: 5rem 0; }
.section--bg { background: var(--gri-bg); }
.sr-only     { position:absolute; width:1px; height:1px; overflow:hidden; clip:rect(0 0 0 0); }

.btn {
  display: inline-flex; align-items: center; gap: .5rem;
  padding: .85rem 2rem; border-radius: 50px;
  font-family: var(--font); font-weight: 700; font-size: .95rem;
  border: none; cursor: pointer; transition: all .25s;
}
.btn--primary {
  background: var(--portocaliu); color: var(--alb);
  box-shadow: 0 4px 14px rgba(255,107,53,.35);
}
.btn--primary:hover  { background: var(--portocaliu-dk); transform: translateY(-2px); box-shadow: 0 6px 20px rgba(255,107,53,.5); }
.btn--ghost { background: transparent; color: var(--alb); border: 2px solid rgba(255,255,255,.5); }
.btn--ghost:hover { background: rgba(255,255,255,.1); border-color: var(--alb); }
.btn--sm { padding: .55rem 1.2rem; font-size: .85rem; }

.badge {
  display: inline-block; padding: .25rem .75rem; border-radius: 20px;
  font-size: .72rem; font-weight: 700; text-transform: uppercase; letter-spacing: .05em;
  background: var(--portocaliu); color: var(--alb);
}

.tag { background: #fff3ee; color: var(--portocaliu-dk); border: 1px solid #ffd5c2; }

/* ── NAVIGATION ────────────────────────────────────────────── */
.nav {
  position: sticky; top: 0; z-index: 1000;
  background: var(--antracit);
  box-shadow: 0 2px 12px rgba(0,0,0,.3);
}
.nav__inner {
  display: flex; justify-content: space-between; align-items: center;
  max-width: var(--max-w); margin: 0 auto; padding: 1rem 1.5rem;
}
.nav__logo {
  display: flex; align-items: center; gap: .6rem;
  color: var(--alb); font-weight: 800; font-size: 1.5rem;
}
.nav__logo-badge {
  background: var(--portocaliu); color: var(--alb);
  width: 40px; height: 40px; border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.5rem; font-weight: 800; flex-shrink: 0;
}
.nav__links { display: flex; gap: 2rem; list-style: none; }
.nav__links a { color: rgba(255,255,255,.85); font-weight: 600; font-size: .9rem; transition: color .2s; }
.nav__links a:hover { color: var(--portocaliu); }
.nav__hamburger { display: none; background: none; border: none; color: var(--alb); cursor: pointer; padding: .25rem; }
.nav__hamburger svg { width: 24px; height: 24px; }

@media (max-width: 768px) {
  .nav__hamburger { display: block; }
  .nav__links { display: none; flex-direction: column; gap: .75rem; padding: 1rem 1.5rem 1.5rem;
    position: absolute; top: 100%; left: 0; right: 0; background: var(--antracit); }
  .nav__links.open { display: flex; }
}

/* ── HERO ───────────────────────────────────────────────────── */
.hero {
  background: linear-gradient(135deg, var(--antracit) 0%, #2c1810 100%);
  color: var(--alb); padding: 7rem 1.5rem 5rem; text-align: center;
  position: relative; overflow: hidden;
}
.hero::before {
  content: ''; position: absolute; inset: 0;
  background: radial-gradient(ellipse at 60% 40%, rgba(255,107,53,.12) 0%, transparent 65%);
}
.hero__content { max-width: 780px; margin: 0 auto; position: relative; }
.hero__eyebrow { font-size: .8rem; font-weight: 700; letter-spacing: .15em; text-transform: uppercase;
  color: var(--portocaliu); margin-bottom: 1.2rem; }
.hero__title { font-size: clamp(2.4rem, 5vw, 4rem); font-weight: 800; line-height: 1.15; margin-bottom: 1rem; }
.hero__tagline { font-size: 1.25rem; color: var(--portocaliu); font-weight: 700; margin-bottom: 1.5rem; }
.hero__desc { font-size: 1.05rem; line-height: 1.8; margin-bottom: 2.5rem; color: rgba(255,255,255,.8); }
.hero__actions { display: flex; gap: 1rem; justify-content: center; flex-wrap: wrap; }
.hero__stats { display: flex; gap: 2.5rem; justify-content: center; margin-top: 3.5rem; flex-wrap: wrap; }
.hero__stat-value { font-size: 2rem; font-weight: 800; color: var(--portocaliu); }
.hero__stat-label { font-size: .8rem; color: rgba(255,255,255,.6); margin-top: .2rem; }

/* ── SECTION HEADING ───────────────────────────────────────── */
.section-heading { text-align: center; margin-bottom: 3rem; }
.section-heading h2 { font-size: clamp(1.8rem, 3vw, 2.5rem); font-weight: 700; }
.section-heading__line {
  width: 72px; height: 4px; background: var(--portocaliu);
  border-radius: 2px; margin: .8rem auto 0;
}
.section-heading p { margin-top: 1rem; color: var(--gri-text); max-width: 560px; margin-left: auto; margin-right: auto; }

/* ── CATEGORY GRID ─────────────────────────────────────────── */
.categories-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.75rem;
}
.category-card {
  background: var(--alb); border-radius: var(--radius);
  padding: 1.8rem; border-left: 4px solid var(--portocaliu);
  box-shadow: var(--shadow-sm); cursor: pointer;
  transition: all .25s;
}
.category-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); border-left-width: 6px; }
.category-card__icon { font-size: 2.5rem; margin-bottom: 1rem; }
.category-card__title { font-size: 1.2rem; font-weight: 700; margin-bottom: .5rem; }
.category-card__desc { font-size: .9rem; color: var(--gri-text); line-height: 1.6; margin-bottom: 1rem; }
.category-card__count { font-size: .8rem; color: var(--portocaliu); font-weight: 600; }

/* ── ARTICLE CARDS ─────────────────────────────────────────── */
.articles-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 2rem;
}
.article-card {
  background: var(--alb); border-radius: var(--radius);
  overflow: hidden; box-shadow: var(--shadow-sm); transition: all .25s;
  display: flex; flex-direction: column;
}
.article-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.article-card__img {
  width: 100%; height: 200px; object-fit: cover;
  background: linear-gradient(135deg, var(--antracit), var(--portocaliu-dk));
  display: flex; align-items: center; justify-content: center;
  font-size: 3.5rem; color: var(--alb);
}
.article-card__body { padding: 1.5rem; flex: 1; display: flex; flex-direction: column; }
.article-card__meta { display: flex; gap: .5rem; align-items: center; margin-bottom: .8rem; flex-wrap: wrap; }
.article-card__title { font-size: 1.15rem; font-weight: 700; margin-bottom: .6rem; line-height: 1.4; }
.article-card__excerpt { font-size: .9rem; color: var(--gri-text); flex: 1; line-height: 1.6; margin-bottom: 1rem; }
.article-card__footer { display: flex; justify-content: space-between; align-items: center; }
.article-card__date { font-size: .78rem; color: var(--gri-text); }
.article-card__read { color: var(--portocaliu); font-weight: 700; font-size: .88rem;
  display: inline-flex; align-items: center; gap: .3rem; transition: gap .2s; }
.article-card__read:hover { gap: .6rem; }

/* ── ARTICLE PAGE ──────────────────────────────────────────── */
.article-page { max-width: 780px; margin: 0 auto; padding: 3rem 1.5rem 5rem; }
.article-page__header { margin-bottom: 2.5rem; }
.article-page__title { font-size: clamp(1.8rem, 3vw, 2.8rem); font-weight: 800; line-height: 1.25; margin-bottom: 1rem; }
.article-page__meta { display: flex; gap: 1rem; align-items: center; flex-wrap: wrap; color: var(--gri-text); font-size: .88rem; }
.article-page__cover { width: 100%; max-height: 420px; object-fit: cover; border-radius: var(--radius); margin-bottom: 2.5rem; }
.article-page__content { font-size: 1.05rem; line-height: 1.9; color: #333; }
.article-page__content h2 { font-size: 1.5rem; font-weight: 700; margin: 2.5rem 0 1rem; color: var(--text-main); }
.article-page__content h3 { font-size: 1.2rem; font-weight: 700; margin: 2rem 0 .8rem; }
.article-page__content p { margin-bottom: 1.25rem; }
.article-page__content ul, .article-page__content ol { margin: 1rem 0 1.25rem 1.5rem; }
.article-page__content li { margin-bottom: .5rem; }
.article-page__content img { border-radius: var(--radius-sm); margin: 1.5rem 0; }
.article-page__content blockquote {
  border-left: 4px solid var(--portocaliu); padding: 1rem 1.5rem;
  background: #fff8f5; border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  margin: 1.5rem 0; font-style: italic; color: var(--gri-text);
}

.pdf-download {
  display: flex; align-items: center; gap: 1rem; padding: 1.25rem 1.5rem;
  background: #fff8f5; border: 1px solid #ffd5c2; border-radius: var(--radius-sm);
  margin: 2rem 0;
}
.pdf-download__icon { font-size: 2rem; }
.pdf-download__text strong { display: block; font-weight: 700; margin-bottom: .2rem; }
.pdf-download__text span { font-size: .85rem; color: var(--gri-text); }

/* ── VIDEO EMBED ───────────────────────────────────────────── */
.video-embed { border-radius: var(--radius); overflow: hidden; aspect-ratio: 16/9; margin: 2rem 0; }
.video-embed iframe { width: 100%; height: 100%; border: none; }

/* ── SEARCH BAR ────────────────────────────────────────────── */
.search-bar { display: flex; gap: .75rem; max-width: 560px; margin: 0 auto 3rem; }
.search-bar input {
  flex: 1; padding: .9rem 1.25rem; border: 2px solid var(--gri-border);
  border-radius: 50px; font-family: var(--font); font-size: 1rem;
  transition: border-color .2s;
}
.search-bar input:focus { outline: none; border-color: var(--portocaliu); }
.search-bar button { flex-shrink: 0; }

/* ── COMMENTS ──────────────────────────────────────────────── */
.comments { margin-top: 4rem; padding-top: 3rem; border-top: 1px solid var(--gri-border); }
.comments h3 { font-size: 1.4rem; font-weight: 700; margin-bottom: 2rem; }
.comment-form { background: var(--gri-bg); padding: 1.75rem; border-radius: var(--radius); margin-bottom: 2.5rem; }
.comment-form h4 { font-weight: 700; margin-bottom: 1.25rem; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin-bottom: 1rem; }
.form-group { display: flex; flex-direction: column; gap: .4rem; margin-bottom: 1rem; }
.form-group label { font-weight: 600; font-size: .88rem; }
.form-group input, .form-group textarea, .form-group select {
  padding: .75rem 1rem; border: 2px solid var(--gri-border); border-radius: var(--radius-sm);
  font-family: var(--font); font-size: .95rem; transition: border-color .2s; background: var(--alb);
}
.form-group input:focus, .form-group textarea:focus { outline: none; border-color: var(--portocaliu); }
.form-group textarea { min-height: 120px; resize: vertical; }

.comment-item { padding: 1.25rem; border-radius: var(--radius-sm); background: var(--gri-bg); margin-bottom: 1rem; }
.comment-item--reply { margin-left: 2rem; border-left: 3px solid var(--portocaliu); }
.comment-item__header { display: flex; justify-content: space-between; align-items: center; margin-bottom: .6rem; flex-wrap: wrap; gap: .5rem; }
.comment-item__author { font-weight: 700; font-size: .95rem; }
.comment-item__date { font-size: .78rem; color: var(--gri-text); }
.comment-item__text { font-size: .93rem; line-height: 1.7; margin-bottom: .5rem; }
.comment-item__reply-btn { background: none; border: none; color: var(--portocaliu); font-weight: 600; font-size: .82rem; cursor: pointer; font-family: var(--font); }

/* ── NEWSLETTER ────────────────────────────────────────────── */
.newsletter-section {
  background: linear-gradient(135deg, var(--antracit), var(--antracit-mid));
  color: var(--alb); padding: 5rem 1.5rem; text-align: center;
}
.newsletter-section h2 { font-size: clamp(1.6rem,3vw,2.2rem); font-weight: 700; margin-bottom: .75rem; }
.newsletter-section p { color: rgba(255,255,255,.75); margin-bottom: 2rem; font-size: 1.05rem; }
.newsletter-form { max-width: 480px; margin: 0 auto; display: flex; gap: .75rem; flex-wrap: wrap; justify-content: center; }
.newsletter-form input { flex: 1; min-width: 220px; padding: .9rem 1.4rem; border: none; border-radius: 50px; font-family: var(--font); font-size: .95rem; }
.newsletter-form input:focus { outline: 2px solid var(--portocaliu); }

/* ── TOAST NOTIFICATIONS ───────────────────────────────────── */
.toast-container { position: fixed; bottom: 1.5rem; right: 1.5rem; z-index: 9999; display: flex; flex-direction: column; gap: .5rem; }
.toast {
  padding: .9rem 1.4rem; border-radius: var(--radius-sm); font-weight: 600; font-size: .9rem;
  color: var(--alb); box-shadow: var(--shadow-lg);
  animation: slideIn .3s ease; max-width: 340px;
}
.toast--success { background: #2d7a4f; }
.toast--error   { background: #c0392b; }
.toast--info    { background: var(--portocaliu); }
@keyframes slideIn { from { transform: translateX(110%); opacity: 0; } to { transform: translateX(0); opacity: 1; } }

/* ── LOADER ────────────────────────────────────────────────── */
.loader { display: flex; justify-content: center; align-items: center; padding: 4rem; }
.loader__spinner {
  width: 40px; height: 40px; border: 3px solid var(--gri-border);
  border-top-color: var(--portocaliu); border-radius: 50%;
  animation: spin .8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

.empty-state { text-align: center; padding: 4rem 2rem; color: var(--gri-text); }
.empty-state__icon { font-size: 3rem; margin-bottom: 1rem; }
.empty-state h3 { font-size: 1.2rem; font-weight: 700; color: var(--text-main); margin-bottom: .5rem; }

/* ── BREADCRUMB ────────────────────────────────────────────── */
.breadcrumb { display: flex; gap: .5rem; align-items: center; font-size: .85rem; color: var(--gri-text); flex-wrap: wrap; }
.breadcrumb a { color: var(--portocaliu); font-weight: 600; }
.breadcrumb span { opacity: .5; }

/* ── FOOTER ────────────────────────────────────────────────── */
.footer { background: var(--antracit); color: var(--alb); padding: 4rem 1.5rem 2rem; }
.footer__grid { max-width: var(--max-w); margin: 0 auto; display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 2.5rem; margin-bottom: 2.5rem; }
.footer__logo { font-size: 1.5rem; font-weight: 800; margin-bottom: .75rem; display: flex; align-items: center; gap: .5rem; }
.footer__tagline { color: rgba(255,255,255,.5); font-size: .88rem; line-height: 1.6; }
.footer__heading { color: var(--portocaliu); font-weight: 700; font-size: .95rem; margin-bottom: 1rem; }
.footer__links { list-style: none; }
.footer__links li { margin-bottom: .5rem; }
.footer__links a { color: rgba(255,255,255,.7); font-size: .9rem; transition: color .2s; }
.footer__links a:hover { color: var(--portocaliu); }
.footer__bottom { max-width: var(--max-w); margin: 0 auto; padding-top: 1.5rem; border-top: 1px solid rgba(255,255,255,.1); text-align: center; font-size: .82rem; color: rgba(255,255,255,.4); }

/* ── RESPONSIVE ────────────────────────────────────────────── */
@media (max-width: 640px) {
  .section { padding: 3.5rem 0; }
  .hero { padding: 5rem 1rem 3.5rem; }
  .hero__actions { flex-direction: column; align-items: center; }
  .form-row { grid-template-columns: 1fr; }
  .articles-grid, .categories-grid { grid-template-columns: 1fr; }
  .comment-item--reply { margin-left: .75rem; }
}
