/* ============================================
   DRUIDSEC - Cybersecurity Consultancy
   Green-themed dark design
   ============================================ */

/* --- Self-hosted Fonts --- */
@font-face { font-family: 'DM Sans'; font-style: normal; font-weight: 400; font-display: swap; src: url('fonts/dm-sans-400.ttf') format('truetype'); }
@font-face { font-family: 'DM Sans'; font-style: normal; font-weight: 500; font-display: swap; src: url('fonts/dm-sans-500.ttf') format('truetype'); }
@font-face { font-family: 'DM Sans'; font-style: normal; font-weight: 700; font-display: swap; src: url('fonts/dm-sans-700.ttf') format('truetype'); }
@font-face { font-family: 'Manrope'; font-style: normal; font-weight: 400; font-display: swap; src: url('fonts/manrope-400.ttf') format('truetype'); }
@font-face { font-family: 'Manrope'; font-style: normal; font-weight: 500; font-display: swap; src: url('fonts/manrope-500.ttf') format('truetype'); }
@font-face { font-family: 'Manrope'; font-style: normal; font-weight: 600; font-display: swap; src: url('fonts/manrope-600.ttf') format('truetype'); }
@font-face { font-family: 'Manrope'; font-style: normal; font-weight: 700; font-display: swap; src: url('fonts/manrope-700.ttf') format('truetype'); }
@font-face { font-family: 'Manrope'; font-style: normal; font-weight: 800; font-display: swap; src: url('fonts/manrope-800.ttf') format('truetype'); }
@font-face { font-family: 'Metamorphous'; font-style: normal; font-weight: 400; font-display: swap; src: url('fonts/metamorphous-400.ttf') format('truetype'); }

/* --- CSS Custom Properties --- */
:root {
  --green-50: #f0fdf4;
  --green-100: #dcfce7;
  --green-200: #bbf7d0;
  --green-300: #86efac;
  --green-400: #4ade80;
  --green-500: #22c55e;
  --green-600: #16a34a;
  --green-700: #15803d;
  --green-800: #166534;

  --primary: #22c55e;
  --primary-light: #4ade80;
  --primary-dim: #16a34a;
  --primary-glow: rgba(34, 197, 94, 0.3);
  --primary-glow-strong: rgba(34, 197, 94, 0.5);

  --bg-dark: #0a0f0d;
  --bg-section: #0d1410;
  --bg-section-alt: #0f1a15;
  --bg-card: #111c16;
  --bg-card-hover: #152419;
  --bg-input: #111c16;

  --text-primary: #f0fdf4;
  --text-secondary: #a3c4b0;
  --text-dim: #6b8f7a;
  --border-color: #1e3a2b;
  --border-hover: #22c55e;

  --font-heading: 'Manrope', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-body: 'DM Sans', -apple-system, BlinkMacSystemFont, sans-serif;

  --container-max: 1200px;
  --section-padding: 6rem 0;
  --radius: 12px;
  --radius-sm: 8px;
  --transition: 0.3s ease;
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: 80px;
}

body {
  font-family: var(--font-body);
  background-color: var(--bg-dark);
  color: var(--text-primary);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* --- Utility --- */
.container {
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 2rem;
}

.section-title {
  font-family: var(--font-heading);
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 800;
  margin-bottom: 1.5rem;
  color: var(--text-primary);
}

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.85rem 2rem;
  border-radius: var(--radius-sm);
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 1rem;
  text-decoration: none;
  cursor: pointer;
  transition: all var(--transition);
  border: none;
}

.btn-primary {
  background: var(--primary);
  color: var(--bg-dark);
}

.btn-primary:hover {
  background: var(--primary-light);
  box-shadow: 0 0 30px var(--primary-glow);
}

.btn-secondary {
  background: transparent;
  color: var(--primary);
  border: 1.5px solid var(--primary);
}

.btn-secondary:hover {
  background: rgba(34, 197, 94, 0.1);
  box-shadow: 0 0 20px var(--primary-glow);
}

.btn-full {
  width: 100%;
}

/* ============================================
   NAVIGATION
   ============================================ */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: rgba(10, 15, 13, 0.85);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border-color);
  transition: all var(--transition);
}

.navbar.scrolled {
  background: rgba(10, 15, 13, 0.95);
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.3);
}

.nav-container {
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  text-decoration: none;
  color: var(--text-primary);
}

.logo-icon {
  font-size: 1.6rem;
  color: var(--primary);
}

.logo-img {
  height: 3.5rem;
  width: 3.5rem;
  object-fit: contain;
}

.logo-text {
  font-family: 'Metamorphous', var(--font-heading);
  font-weight: 800;
  font-size: 1.6rem;
  letter-spacing: 3px;
}

.nav-links {
  display: flex;
  list-style: none;
  align-items: center;
  gap: 2rem;
}

.nav-links a {
  color: var(--text-secondary);
  text-decoration: none;
  font-family: var(--font-heading);
  font-weight: 500;
  font-size: 0.95rem;
  transition: color var(--transition);
}

.nav-links a:hover {
  color: var(--primary);
}

.nav-cta {
  background: var(--primary);
  color: var(--bg-dark) !important;
  padding: 0.5rem 1.25rem;
  border-radius: var(--radius-sm);
  font-weight: 600 !important;
}

.nav-cta:hover {
  background: var(--primary-light) !important;
}

/* Mobile nav toggle */
.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}

.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--text-primary);
  transition: all var(--transition);
}

/* ============================================
   HERO
   ============================================ */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  padding: 8rem 2rem 6rem;
}

.hero-bg {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 20% 50%, rgba(34, 197, 94, 0.08) 0%, transparent 60%),
    radial-gradient(ellipse at 80% 20%, rgba(34, 197, 94, 0.05) 0%, transparent 50%),
    radial-gradient(ellipse at 50% 100%, rgba(34, 197, 94, 0.06) 0%, transparent 40%);
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, var(--bg-dark) 0%, transparent 30%, transparent 70%, var(--bg-dark) 100%);
}

.hero-particles {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
}

.particle {
  position: absolute;
  width: 2px;
  height: 2px;
  background: var(--primary);
  border-radius: 50%;
  animation: float linear infinite;
  opacity: 0;
}

@keyframes float {
  0% {
    opacity: 0;
    transform: translateY(100vh) scale(0);
  }
  10% {
    opacity: 0.6;
  }
  90% {
    opacity: 0.6;
  }
  100% {
    opacity: 0;
    transform: translateY(-10vh) scale(1);
  }
}

.hero-content {
  position: relative;
  z-index: 1;
  text-align: center;
  max-width: 800px;
}

.hero-title {
  font-family: var(--font-heading);
  font-size: clamp(2.5rem, 6vw, 4.5rem);
  font-weight: 800;
  line-height: 1.1;
  margin-bottom: 1.5rem;
  background: linear-gradient(135deg, var(--text-primary) 0%, var(--primary-light) 50%, var(--primary) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-subtitle {
  font-size: clamp(1.05rem, 2vw, 1.25rem);
  color: var(--text-secondary);
  max-width: 600px;
  margin: 0 auto 2.5rem;
  line-height: 1.7;
}

.hero-ctas {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
}

/* ============================================
   SERVICES
   ============================================ */
.services {
  padding: var(--section-padding);
  background: var(--bg-section);
}

.services .section-title {
  text-align: center;
  margin-bottom: 3rem;
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 1.25rem;
}

.service-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  padding: 1.75rem;
  transition: all var(--transition);
  cursor: default;
}

.service-card:hover {
  background: var(--bg-card-hover);
  border-color: var(--primary-dim);
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(34, 197, 94, 0.08);
}

.service-icon {
  width: 44px;
  height: 44px;
  margin-bottom: 1rem;
  color: var(--primary);
}

.service-icon svg {
  width: 100%;
  height: 100%;
}

.service-card h3 {
  font-family: var(--font-heading);
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--text-primary);
}

.services-note {
  text-align: center;
  color: var(--text-secondary);
  margin-top: 3rem;
  font-size: 1.05rem;
  max-width: 700px;
  margin-left: auto;
  margin-right: auto;
}

/* ============================================
   ABOUT
   ============================================ */
.about {
  padding: var(--section-padding);
  background: var(--bg-section-alt);
}

.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: start;
}

.about-content p {
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
  font-size: 1.05rem;
  line-height: 1.8;
}

.about-content h3 {
  font-family: var(--font-heading);
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--primary-light);
  margin-top: 2rem;
  margin-bottom: 0.75rem;
}

/* Terminal visual */
.terminal-window {
  background: #0c0c0c;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border-color);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4);
  position: sticky;
  top: 100px;
}

.terminal-header {
  background: #1a1a1a;
  padding: 0.75rem 1rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.terminal-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
}

.terminal-dot.red { background: #ff5f57; }
.terminal-dot.yellow { background: #febc2e; }
.terminal-dot.green { background: #28c840; }

.terminal-title {
  margin-left: 0.75rem;
  font-family: 'Courier New', monospace;
  font-size: 0.8rem;
  color: var(--text-dim);
}

.terminal-body {
  padding: 1.25rem;
  font-family: 'Courier New', monospace;
  font-size: 0.85rem;
  line-height: 1.8;
}

.terminal-line {
  color: var(--text-primary);
}

.terminal-line.dim {
  color: var(--text-dim);
}

.terminal-line.success {
  color: var(--primary);
}

.terminal-line.cursor {
  color: var(--primary);
  animation: blink 1s step-end infinite;
}

@keyframes blink {
  50% { opacity: 0; }
}

/* ============================================
   FAQ
   ============================================ */
.faq {
  padding: var(--section-padding);
  background: var(--bg-section);
}

.faq-header {
  text-align: center;
  margin-bottom: 3rem;
}

.faq-subtitle {
  color: var(--text-secondary);
  font-size: 1.1rem;
  max-width: 600px;
  margin: 0 auto 2rem;
}

.faq-list {
  max-width: 800px;
  margin: 0 auto;
}

.faq-item {
  border-bottom: 1px solid var(--border-color);
}

.faq-question {
  width: 100%;
  background: none;
  border: none;
  padding: 1.5rem 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  cursor: pointer;
  text-align: left;
  font-family: var(--font-heading);
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text-primary);
  transition: color var(--transition);
}

.faq-question:hover {
  color: var(--primary);
}

.faq-chevron {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  color: var(--text-dim);
  transition: transform var(--transition);
}

.faq-item.open .faq-chevron {
  transform: rotate(180deg);
  color: var(--primary);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s ease, padding 0.4s ease;
}

.faq-item.open .faq-answer {
  max-height: 300px;
}

.faq-answer p {
  color: var(--text-secondary);
  padding-bottom: 1.5rem;
  font-size: 1.05rem;
  line-height: 1.7;
}

/* ============================================
   CONTACT
   ============================================ */
.contact {
  padding: var(--section-padding);
  background: var(--bg-section-alt);
}

.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: start;
}

.contact-info p {
  color: var(--text-secondary);
  font-size: 1.1rem;
  line-height: 1.7;
  margin-bottom: 2rem;
}

.contact-form {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.form-group label {
  font-family: var(--font-heading);
  font-weight: 500;
  font-size: 0.9rem;
  color: var(--text-secondary);
}

.form-group input,
.form-group textarea {
  background: var(--bg-input);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  padding: 0.85rem 1rem;
  color: var(--text-primary);
  font-family: var(--font-body);
  font-size: 1rem;
  transition: border-color var(--transition), box-shadow var(--transition);
  outline: none;
}

.form-group input:focus,
.form-group textarea:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px var(--primary-glow);
}

.form-group textarea {
  resize: vertical;
  min-height: 120px;
}

.form-group input::placeholder,
.form-group textarea::placeholder {
  color: var(--text-dim);
}

.form-status {
  text-align: center;
  font-size: 0.95rem;
  min-height: 1.5rem;
}

.form-status.success {
  color: var(--primary);
}

.form-status.error {
  color: #ef4444;
}

/* ============================================
   FOOTER
   ============================================ */
.footer {
  padding: 3rem 0;
  background: var(--bg-dark);
  border-top: 1px solid var(--border-color);
}

.footer-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.5rem;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.footer-brand .logo-icon {
  font-size: 1.3rem;
}

.footer-brand .logo-text {
  font-size: 1.1rem;
}

.footer-links {
  display: flex;
  gap: 2rem;
}

.footer-links a {
  color: var(--text-dim);
  text-decoration: none;
  font-size: 0.9rem;
  transition: color var(--transition);
}

.footer-links a:hover {
  color: var(--primary);
}

.footer-copy {
  color: var(--text-dim);
  font-size: 0.85rem;
}

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 900px) {
  .about-grid,
  .contact-grid {
    grid-template-columns: 1fr;
    gap: 2.5rem;
  }

  .terminal-window {
    position: static;
  }
}

@media (max-width: 768px) {
  :root {
    --section-padding: 4rem 0;
  }

  .nav-toggle {
    display: flex;
  }

  .nav-links {
    position: fixed;
    top: 72px;
    left: 0;
    right: 0;
    background: rgba(10, 15, 13, 0.97);
    backdrop-filter: blur(20px);
    flex-direction: column;
    padding: 2rem;
    gap: 1.5rem;
    transform: translateY(-100%);
    opacity: 0;
    pointer-events: none;
    transition: all var(--transition);
    border-bottom: 1px solid var(--border-color);
  }

  .nav-links.open {
    transform: translateY(0);
    opacity: 1;
    pointer-events: all;
  }

  .hero {
    padding: 7rem 1.5rem 4rem;
    min-height: auto;
  }

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

  .hero-ctas {
    flex-direction: column;
    align-items: center;
  }
}
