/*
Theme Name: HIND EL ATMANI
Theme URI: https://hindelatmani.com
Author: Hind El Atmani
Description: A modern, elegant personal website theme. Fully editable through WordPress Customizer and Pages. Features interactive 3D globe, scroll animations, and a sophisticated editorial design.
Version: 3.0.0
Requires at least: 5.8
Tested up to: 6.5
Requires PHP: 7.4
License: GPLv2 or later
Text Domain: hind-el-atmani
*/

/* ===== BASE / RESET ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: 'Cormorant Garamond', Georgia, serif;
  color: #1A1A1A;
  background-color: #EAE8E1;
  overflow-x: hidden;
  font-size: 18px;
  line-height: 1.7;
}
h1, h2, h3, h4, h5, h6 {
  font-family: 'Playfair Display', Georgia, serif;
  font-weight: 400;
  letter-spacing: -0.5px;
  line-height: 1.15;
  color: #1A1A1A;
}
a { text-decoration: none; color: inherit; transition: color 0.3s ease; }
img { max-width: 100%; height: auto; display: block; }
figure { margin: 0; }

/* ===== NAVIGATION ===== */
.site-nav {
  position: fixed;
  top: 0; left: 0; width: 100%;
  z-index: 100;
  padding: 20px 48px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  transition: all 0.4s ease;
  background: transparent;
}
.site-nav.scrolled {
  background-color: rgba(234, 232, 225, 0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(26, 26, 26, 0.06);
}
.site-nav .nav-logo {
  font-family: 'Playfair Display', serif;
  font-size: 20px;
  font-weight: 400;
  letter-spacing: 3px;
  color: #1A1A1A;
}
.site-nav .nav-menu {
  display: flex;
  gap: 36px;
  align-items: center;
  list-style: none;
  margin: 0;
  padding: 0;
}
.site-nav .nav-menu a {
  font-family: 'Cormorant Garamond', serif;
  font-size: 15px;
  font-weight: 500;
  color: #1A1A1A;
  position: relative;
  padding: 4px 0;
  letter-spacing: 0.5px;
  transition: color 0.3s ease;
}
.site-nav .nav-menu a:hover { color: #E9B81D; }
.site-nav .nav-menu a.current-menu-item,
.site-nav .nav-menu a.current-page-item { color: #8B6914; }
.site-nav .nav-menu a::after {
  content: '';
  position: absolute;
  bottom: -2px; left: 0;
  width: 0; height: 1px;
  background-color: #E9B81D;
  transition: width 0.3s ease;
}
.site-nav .nav-menu a:hover::after,
.site-nav .nav-menu a.current-menu-item::after,
.site-nav .nav-menu a.current-page-item::after { width: 100%; }

/* Mobile */
.nav-mobile-toggle { display: none; background: none; border: none; cursor: pointer; padding: 8px; }
.nav-mobile-toggle span { display: block; width: 24px; height: 2px; background: #1A1A1A; margin-bottom: 6px; transition: all 0.3s; }
.nav-mobile-menu { display: none; }

@media (max-width: 768px) {
  .site-nav { padding: 16px 24px; }
  .site-nav .nav-menu { display: none !important; }
  .nav-mobile-toggle { display: block !important; }
  .nav-mobile-menu.open {
    position: fixed; top: 0; left: 0; width: 100%; height: 100vh;
    background: #EAE8E1; z-index: 99;
    display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 32px;
  }
  .nav-mobile-menu a { font-family: 'Playfair Display', serif; font-size: 28px; color: #1A1A1A; }
  .nav-mobile-menu a.current-menu-item { color: #8B6914; }
}

/* ===== HERO ===== */
.hero-section {
  position: relative;
  width: 100vw;
  height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #EAE8E1;
  overflow: hidden;
}
.hero-canvas { position: absolute; top: 0; left: 0; width: 100%; height: 100%; z-index: 1; }
.hero-vignette { position: absolute; top: 0; left: 0; width: 100%; height: 100%; background: radial-gradient(ellipse at center, transparent 30%, rgba(245, 240, 235, 0.6) 100%); z-index: 2; pointer-events: none; }
.hero-content { position: relative; z-index: 3; text-align: center; }
.hero-name { font-family: 'Playfair Display', serif; font-size: clamp(48px, 10vw, 120px); font-weight: 400; letter-spacing: 8px; color: #1A1A1A; line-height: 1; margin: 0; }
.hero-line { width: 60px; height: 1px; background: #E9B81D; margin: 24px auto; }
.hero-tagline { font-family: 'Cormorant Garamond', serif; font-size: 14px; font-weight: 500; letter-spacing: 5px; text-transform: uppercase; color: #888888; margin: 0; }
.hero-scroll { position: absolute; bottom: 40px; left: 50%; transform: translateX(-50%); z-index: 3; display: flex; flex-direction: column; align-items: center; gap: 8px; }
.hero-scroll p { font-family: 'Cormorant Garamond', serif; font-size: 12px; letter-spacing: 2px; text-transform: uppercase; color: #888888; }
.hero-scroll-line { width: 1px; height: 30px; background: linear-gradient(to bottom, #E9B81D, transparent); animation: scrollPulse 2s ease-in-out infinite; }
@keyframes scrollPulse { 0%, 100% { opacity: 0.4; transform: scaleY(0.8); } 50% { opacity: 1; transform: scaleY(1.2); } }

/* ===== CONTENT AREAS ===== */
.section-padding { padding: 100px 0; }
.container { max-width: 1280px; margin: 0 auto; padding: 0 48px; }
.label-text { font-family: 'Cormorant Garamond', serif; font-size: 14px; font-weight: 500; letter-spacing: 3px; text-transform: uppercase; color: #E9B81D; margin-bottom: 16px; }
@media (max-width: 768px) { .container { padding: 0 24px; } }

/* ===== PAGE HEADER (dark) ===== */
.page-header { background: #252525; padding: 160px 0 80px; text-align: center; }
.page-header .label-text { color: #E9B81D; margin-bottom: 20px; }
.page-header h1 { color: #EAE8E1; font-size: clamp(36px, 5vw, 56px); }
.page-header p { color: #888888; font-size: 18px; max-width: 700px; margin: 20px auto 0; line-height: 1.7; }

/* ===== EDITOR CONTENT (from WordPress) ===== */
.entry-content { font-family: 'Cormorant Garamond', serif; font-size: 18px; line-height: 1.8; color: #555555; }
.entry-content h2 { font-family: 'Playfair Display', serif; font-size: clamp(28px, 3vw, 36px); font-weight: 400; color: #1A1A1A; margin: 40px 0 20px; }
.entry-content h3 { font-family: 'Playfair Display', serif; font-size: 24px; font-weight: 400; color: #1A1A1A; margin: 32px 0 16px; }
.entry-content h4 { font-family: 'Playfair Display', serif; font-size: 20px; font-weight: 400; color: #1A1A1A; margin: 24px 0 12px; }
.entry-content p { margin-bottom: 20px; }
.entry-content strong { color: #1A1A1A; }
.entry-content a { color: #E9B81D; border-bottom: 1px solid #E9B81D; padding-bottom: 2px; }
.entry-content a:hover { color: #D6A710; }
.entry-content ul, .entry-content ol { margin: 16px 0 16px 24px; padding-left: 16px; }
.entry-content li { margin-bottom: 8px; }
.entry-content blockquote { border-left: 3px solid #E9B81D; padding-left: 24px; margin: 24px 0; font-style: italic; color: #555555; }
.entry-content img { border-radius: 4px; margin: 24px 0; }
.entry-content .wp-block-image figcaption { font-size: 14px; color: #888888; text-align: center; margin-top: 8px; }
.entry-content .wp-block-columns { gap: 40px; }

/* ===== ABOUT SECTION ===== */
.about-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 80px; align-items: center; }
.about-portrait { width: 100%; height: 50vw; max-height: 600px; border-radius: 4px; overflow: hidden; }
.about-portrait img { width: 100%; height: 100%; object-fit: cover; }
.about-bio .label-text { margin-bottom: 16px; }
.about-bio h2 { font-size: clamp(32px, 4vw, 44px); margin-bottom: 24px; }
.about-bio p { font-size: 18px; color: #555555; margin-bottom: 20px; line-height: 1.7; }
.about-bio strong { color: #1A1A1A; }

/* Quick Facts */
.quick-facts { background: rgba(37, 37, 37, 0.04); border-radius: 4px; padding: 28px; margin-top: 32px; }
.quick-facts h3 { font-size: 20px; margin-bottom: 20px; }
.fact-item { margin-bottom: 14px; }
.fact-item .fact-label { font-size: 12px; font-weight: 500; letter-spacing: 1.5px; text-transform: uppercase; color: #888888; margin-bottom: 2px; }
.fact-item .fact-value { font-size: 15px; color: #1A1A1A; }

/* Research Interests */
.interests-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: 20px 0; }
.interest-tag { font-size: 15px; color: #555555; padding: 10px 14px; background: rgba(37, 37, 37, 0.04); border-radius: 4px; border-left: 3px solid #E9B81D; }

/* ===== CTA BUTTONS ===== */
.btn-primary { font-family: 'Cormorant Garamond', serif; font-size: 15px; font-weight: 500; color: #EAE8E1; background: #1A1A1A; padding: 12px 28px; border-radius: 4px; transition: all 0.3s ease; display: inline-block; border: none; cursor: pointer; }
.btn-primary:hover { background: #E9B81D; }
.btn-link { font-family: 'Cormorant Garamond', serif; font-size: 15px; font-weight: 500; color: #1A1A1A; border-bottom: 1px solid #1A1A1A; padding-bottom: 4px; transition: all 0.3s ease; display: inline-block; background: none; border-top: none; border-left: none; border-right: none; cursor: pointer; }
.btn-link:hover { color: #E9B81D; border-bottom-color: #E9B81D; transform: translateY(-2px); }
.cta-buttons { display: flex; gap: 20px; margin-top: 40px; flex-wrap: wrap; }

/* ===== DARK SECTION ===== */
.dark-section { background: #252525; }
.dark-section h2, .dark-section h3, .dark-section h4 { color: #EAE8E1; }
.dark-section p { color: #888888; }
.dark-section .btn-link { color: #EAE8E1; border-bottom-color: rgba(234, 232, 225, 0.4); }
.dark-section .btn-link:hover { color: #E9B81D; border-bottom-color: #E9B81D; }

/* ===== GRIDS ===== */
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 24px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 32px; }
@media (max-width: 768px) { .grid-2, .grid-3 { grid-template-columns: 1fr !important; } .about-grid { grid-template-columns: 1fr !important; gap: 40px !important; } .interests-grid { grid-template-columns: 1fr !important; } }

/* ===== CARDS ===== */
.card { background: rgba(37, 37, 37, 0.04); border-radius: 4px; padding: 32px; border-left: 4px solid #E9B81D; transition: transform 0.3s ease; }
.card:hover { transform: translateX(4px); }
.card h3 { font-size: 20px; margin-bottom: 12px; }
.card p { font-size: 16px; color: #555555; line-height: 1.6; }

/* Highlight Cards (dark) */
.highlight-card { background: rgba(245, 240, 235, 0.06); border-radius: 4px; padding: 24px; border-left: 3px solid #E9B81D; margin-bottom: 20px; }
.highlight-card h4 { font-size: 16px; color: #EAE8E1; margin-bottom: 6px; }
.highlight-card p { font-size: 14px; color: #888888; line-height: 1.5; }

/* ===== INSIGHT / BLOG CARDS ===== */
.insight-card { cursor: pointer; }
.insight-image { width: 100%; aspect-ratio: 16/9; border-radius: 4px; overflow: hidden; margin-bottom: 20px; }
.insight-image img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.5s ease; }
.insight-card:hover .insight-image img { transform: scale(1.05); }
.insight-title { font-size: 22px; margin-bottom: 12px; transition: color 0.3s ease; }
.insight-card:hover .insight-title { color: #E9B81D; }
.insight-excerpt { font-size: 16px; line-height: 1.6; color: #888888; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

/* ===== PUBLICATION CARDS ===== */
.publication-card { background: rgba(37, 37, 37, 0.04); border-radius: 4px; padding: 36px; border-left: 4px solid #E9B81D; transition: transform 0.3s ease; }
.publication-card:hover { transform: translateX(4px); }
.publication-card .pub-meta { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 12px; flex-wrap: wrap; gap: 8px; }
.publication-card .pub-type { font-size: 13px; font-weight: 500; letter-spacing: 2px; text-transform: uppercase; color: #E9B81D; }
.publication-card .pub-year { font-size: 14px; font-weight: 500; color: #888888; }
.publication-card h3 { font-size: 22px; margin-bottom: 12px; line-height: 1.3; }
.publication-card p { font-size: 16px; color: #555555; margin-bottom: 16px; }
.pub-tags { display: flex; gap: 8px; flex-wrap: wrap; }
.pub-tags span { font-size: 13px; color: #888888; background: rgba(136, 136, 136, 0.12); padding: 4px 12px; border-radius: 4px; }

/* ===== BLOG ===== */
.blog-card { cursor: pointer; }
.blog-image { width: 100%; aspect-ratio: 16/10; border-radius: 4px; overflow: hidden; margin-bottom: 20px; }
.blog-image img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.5s ease; }
.blog-card:hover .blog-image img { transform: scale(1.05); }
.blog-meta-row { display: flex; justify-content: space-between; align-items: center; margin-bottom: 12px; }
.blog-cat { font-size: 12px; font-weight: 500; letter-spacing: 2px; text-transform: uppercase; color: #E9B81D; }
.blog-read { font-size: 13px; color: #888888; }
.blog-title { font-size: 20px; letter-spacing: -0.3px; line-height: 1.3; margin-bottom: 12px; transition: color 0.3s ease; }
.blog-card:hover .blog-title { color: #E9B81D; }
.blog-excerpt { font-size: 15px; line-height: 1.6; color: #888888; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; margin-bottom: 12px; }
.blog-date { font-size: 13px; color: #888888; }

.category-filters { display: flex; gap: 12px; flex-wrap: wrap; justify-content: center; padding-bottom: 40px; border-bottom: 1px solid rgba(26, 26, 26, 0.08); margin-bottom: 40px; }
.category-btn { font-family: 'Cormorant Garamond', serif; font-size: 14px; font-weight: 500; padding: 8px 20px; border-radius: 4px; cursor: pointer; transition: all 0.3s ease; border: 1px solid rgba(26, 26, 26, 0.15); background: transparent; color: #555555; }
.category-btn.active, .category-btn:hover { background: #1A1A1A; color: #EAE8E1; border-color: #1A1A1A; }

/* ===== CONTACT ===== */
.contact-grid { display: grid; grid-template-columns: 1fr 1.2fr; gap: 80px; }
.collab-item { display: flex; gap: 16px; align-items: flex-start; margin-bottom: 28px; }
.collab-icon { font-size: 24px; flex-shrink: 0; }
.collab-item h3 { font-size: 18px; margin-bottom: 6px; }
.collab-item p { font-size: 15px; color: #888888; line-height: 1.6; }

.contact-form-wrapper { background: rgba(37, 37, 37, 0.04); border-radius: 4px; padding: 48px; }
.contact-form-wrapper h3 { font-size: 22px; margin-bottom: 28px; }
.form-group { margin-bottom: 20px; }
.form-group label { font-size: 14px; font-weight: 500; color: #888888; margin-bottom: 8px; display: block; }
.form-group input, .form-group select, .form-group textarea { width: 100%; font-family: 'Cormorant Garamond', serif; font-size: 16px; color: #1A1A1A; background: #EAE8E1; border: 1px solid rgba(26, 26, 26, 0.1); border-radius: 4px; padding: 12px 16px; outline: none; transition: border-color 0.3s ease; }
.form-group input:focus, .form-group select:focus, .form-group textarea:focus { border-color: #E9B81D; }
.form-group textarea { resize: vertical; }

.success-msg { background: rgba(37, 37, 37, 0.04); border-radius: 4px; padding: 48px; text-align: center; }
.success-msg h3 { font-size: 24px; margin-bottom: 12px; }
.success-msg p { font-size: 16px; color: #555555; }

/* ===== FOOTER ===== */
.site-footer { background: #252525; padding: 100px 0 48px; }
.site-footer h2 { font-size: 28px; letter-spacing: 2px; color: #EAE8E1; margin-bottom: 12px; }
.site-footer > .container > .footer-grid > div:first-child > p { font-size: 16px; color: #888888; line-height: 1.7; margin-bottom: 32px; max-width: 400px; }
.site-footer .footer-label { font-size: 14px; font-weight: 500; letter-spacing: 2px; text-transform: uppercase; color: #E9B81D; margin-bottom: 16px; }
.site-footer .footer-nav a { font-size: 16px; color: #888888; display: block; margin-bottom: 12px; transition: color 0.3s ease; }
.site-footer .footer-nav a:hover { color: #EAE8E1; }
.footer-divider { height: 1px; background: rgba(234, 232, 225, 0.08); margin: 32px 0; }
.footer-bottom { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 16px; }
.footer-bottom p { font-size: 14px; color: #888888; }
.newsletter-input { display: flex; align-items: center; gap: 12px; max-width: 400px; border-bottom: 1px solid rgba(234, 232, 225, 0.15); padding-bottom: 8px; }
.newsletter-input input { flex: 1; font-family: 'Cormorant Garamond', serif; font-size: 16px; color: #EAE8E1; background: none; border: none; outline: none; padding: 8px 0; }
.newsletter-input button { font-family: 'Cormorant Garamond', serif; font-size: 14px; font-weight: 500; color: #E9B81D; background: none; border: none; cursor: pointer; padding: 8px 0; }

/* ===== MANIFESTO ===== */
.manifesto-wrapper { position: relative; }
.manifesto-scroll-target { height: 300vh; position: relative; background: #EAE8E1; }
.manifesto-sticky { position: sticky; top: 0; width: 100vw; height: 100vh; background: #EAE8E1; display: flex; align-items: center; overflow: hidden; }
.manifesto-words { display: flex; align-items: center; gap: 60px; padding-left: 10vw; white-space: nowrap; will-change: transform; }
.manifesto-word { font-family: 'Playfair Display', serif; font-size: clamp(50px, 12vh, 140px); font-weight: 400; color: #252525; line-height: 1; letter-spacing: -0.5px; will-change: transform, opacity; transition: transform 0.1s linear, opacity 0.1s linear; flex-shrink: 0; }

/* ===== ANIMATIONS ===== */
.fade-in-up { opacity: 0; transform: translateY(30px); transition: all 0.8s ease; }
.fade-in-up.visible { opacity: 1; transform: translateY(0); }

/* ===== PAGINATION ===== */
.pagination { display: flex; justify-content: center; gap: 8px; margin-top: 48px; list-style: none; padding: 0; }
.pagination a, .pagination span { font-family: 'Cormorant Garamond', serif; font-size: 16px; padding: 8px 16px; border-radius: 4px; color: #555555; transition: all 0.3s ease; }
.pagination a:hover { background: #1A1A1A; color: #EAE8E1; }
.pagination .current { background: #1A1A1A; color: #EAE8E1; }

/* ===== CONTACT FORM ===== */
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
@media (max-width: 768px) { .form-row { grid-template-columns: 1fr !important; } .research-grid { grid-template-columns: 1fr !important; gap: 40px !important; } }

/* ===== ADMIN BAR FIX ===== */
.admin-bar .site-nav { top: 32px; }
@media screen and (max-width: 782px) { .admin-bar .site-nav { top: 46px; } }
