/* ============================================
   Dan Ackerman - Single Page Website
   Modern, sleek, responsive design
   ============================================ */

/* --- CSS Custom Properties --- */
:root {
  --bg-primary: #0a0a0f;
  --bg-secondary: #111118;
  --bg-card: #16161f;
  --bg-card-hover: #1c1c28;
  --text-primary: #f0f0f5;
  --text-secondary: #a0a0b8;
  --text-muted: #6b6b82;
  --accent: #6366f1;
  --accent-light: #818cf8;
  --accent-dark: #4f46e5;
  --accent-glow: rgba(99, 102, 241, 0.15);
  --border: rgba(255, 255, 255, 0.06);
  --border-hover: rgba(255, 255, 255, 0.12);
  --gradient-1: linear-gradient(135deg, #6366f1, #8b5cf6);
  --gradient-2: linear-gradient(135deg, #06b6d4, #6366f1);
  --gradient-3: linear-gradient(135deg, #10b981, #06b6d4);
  --shadow-sm: 0 1px 2px rgba(0,0,0,0.3);
  --shadow-md: 0 4px 12px rgba(0,0,0,0.4);
  --shadow-lg: 0 8px 30px rgba(0,0,0,0.5);
  --shadow-glow: 0 0 40px rgba(99, 102, 241, 0.2);
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 20px;
  --radius-xl: 28px;
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-mono: 'JetBrains Mono', 'Fira Code', monospace;
  --nav-height: 72px;
  --container-max: 1200px;
  --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* --- Reset & Base --- */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: var(--nav-height);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font-sans);
  background: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.7;
  overflow-x: hidden;
}

a {
  color: var(--accent-light);
  text-decoration: none;
  transition: color var(--transition);
}

a:hover {
  color: var(--text-primary);
}

img {
  max-width: 100%;
  display: block;
}

/* --- Container --- */
.container {
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 24px;
}

/* --- Navigation --- */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--nav-height);
  z-index: 1000;
  transition: background var(--transition), box-shadow var(--transition), backdrop-filter var(--transition);
}

.nav.scrolled {
  background: rgba(10, 10, 15, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  box-shadow: 0 1px 0 var(--border);
}

.nav-container {
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 24px;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-logo {
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 1.25rem;
  color: var(--text-primary);
  letter-spacing: -0.02em;
  transition: color var(--transition);
}

.nav-logo:hover {
  color: var(--accent-light);
}

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
}

.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--text-primary);
  border-radius: 2px;
  transition: var(--transition);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 8px;
  list-style: none;
}

.nav-links a {
  color: var(--text-secondary);
  font-size: 0.875rem;
  font-weight: 500;
  padding: 8px 16px;
  border-radius: var(--radius-sm);
  transition: all var(--transition);
}

.nav-links a:hover {
  color: var(--text-primary);
  background: rgba(255, 255, 255, 0.05);
}

.nav-cta {
  background: var(--gradient-1) !important;
  color: white !important;
  padding: 8px 20px !important;
  border-radius: var(--radius-sm) !important;
  font-weight: 600 !important;
}

.nav-cta:hover {
  opacity: 0.9;
  transform: translateY(-1px);
  box-shadow: var(--shadow-glow);
}

/* --- Hero --- */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
  padding: calc(var(--nav-height) + 40px) 24px 80px;
}

.hero-bg {
  position: absolute;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
}

.tetris-block {
  position: absolute;
  width: var(--s);
  height: var(--s);
  background: var(--color);
  opacity: 0.06;
  border-radius: 4px;
  animation: float 12s ease-in-out infinite;
  animation-delay: var(--d);
  top: var(--y);
  left: var(--x);
}

@keyframes float {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  25% { transform: translateY(-30px) rotate(5deg); }
  50% { transform: translateY(10px) rotate(-3deg); }
  75% { transform: translateY(-15px) rotate(2deg); }
}

.hero-content {
  position: relative;
  z-index: 1;
  text-align: center;
  max-width: 800px;
}

.hero-photo {
  width: 160px;
  height: 160px;
  margin: 0 auto 28px;
  border-radius: 50%;
  overflow: hidden;
  border: 3px solid var(--accent);
  box-shadow: var(--shadow-glow);
}

.hero-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  display: block;
}

.hero-badge {
  display: inline-block;
  background: var(--accent-glow);
  border: 1px solid rgba(99, 102, 241, 0.2);
  color: var(--accent-light);
  font-family: var(--font-mono);
  font-size: 0.8rem;
  font-weight: 500;
  padding: 6px 18px;
  border-radius: 100px;
  margin-bottom: 28px;
  letter-spacing: 0.02em;
}

.hero-name {
  font-size: clamp(3rem, 8vw, 5.5rem);
  font-weight: 900;
  line-height: 1.05;
  letter-spacing: -0.03em;
  margin-bottom: 20px;
}

.hero-name .accent {
  background: var(--gradient-1);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-subtitle {
  font-size: clamp(1.1rem, 2.5vw, 1.4rem);
  color: var(--text-secondary);
  font-weight: 400;
  margin-bottom: 24px;
  letter-spacing: -0.01em;
}

.hero-desc {
  font-size: 1.05rem;
  color: var(--text-secondary);
  line-height: 1.8;
  margin-bottom: 36px;
  max-width: 640px;
  margin-left: auto;
  margin-right: auto;
}

.hero-desc em {
  color: var(--accent-light);
  font-style: italic;
}

.hero-actions {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  margin-bottom: 40px;
  flex-wrap: wrap;
}

.hero-social {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 20px;
  flex-wrap: wrap;
}

.hero-social a {
  font-size: 0.85rem;
  color: var(--text-muted);
  transition: color var(--transition);
}

.hero-social a:hover {
  color: var(--accent-light);
}

.hero-scroll {
  position: absolute;
  bottom: 32px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  color: var(--text-muted);
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  animation: bounce 2s ease-in-out infinite;
}

@keyframes bounce {
  0%, 100% { transform: translateX(-50%) translateY(0); }
  50% { transform: translateX(-50%) translateY(8px); }
}

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: var(--font-sans);
  font-size: 0.95rem;
  font-weight: 600;
  padding: 12px 28px;
  border-radius: var(--radius-sm);
  border: none;
  cursor: pointer;
  transition: all var(--transition);
  text-decoration: none;
}

.btn-primary {
  background: var(--gradient-1);
  color: white;
  box-shadow: 0 2px 12px rgba(99, 102, 241, 0.3);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 24px rgba(99, 102, 241, 0.4);
  color: white;
}

.btn-outline {
  background: transparent;
  color: var(--text-primary);
  border: 1px solid var(--border-hover);
}

.btn-outline:hover {
  background: rgba(255, 255, 255, 0.05);
  border-color: var(--accent);
  color: var(--accent-light);
}

.btn-large {
  padding: 16px 36px;
  font-size: 1.05rem;
}

.btn-full {
  width: 100%;
}

/* --- Sections --- */
.section {
  padding: 120px 0;
  position: relative;
}

.section-header {
  text-align: center;
  margin-bottom: 64px;
}

.section-tag {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--accent-light);
  background: var(--accent-glow);
  border: 1px solid rgba(99, 102, 241, 0.15);
  padding: 4px 14px;
  border-radius: 100px;
  margin-bottom: 16px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.section-header h2 {
  font-size: clamp(2rem, 4vw, 2.8rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.2;
}

.accent {
  background: var(--gradient-1);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* --- About --- */
.about {
  background: var(--bg-secondary);
}

.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: start;
}

.about-text p {
  color: var(--text-secondary);
  margin-bottom: 20px;
  font-size: 1.02rem;
}

.about-text strong {
  color: var(--text-primary);
}

.about-highlights {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.highlight-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 24px;
  transition: all var(--transition);
}

.highlight-card:hover {
  border-color: var(--border-hover);
  background: var(--bg-card-hover);
  transform: translateY(-2px);
}

.highlight-number {
  font-family: var(--font-mono);
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--accent-light);
  margin-bottom: 6px;
}

.highlight-label {
  font-size: 0.85rem;
  color: var(--text-muted);
}

/* --- Work / Timeline --- */
.timeline {
  position: relative;
  max-width: 700px;
  margin: 0 auto;
}

.timeline::before {
  content: '';
  position: absolute;
  left: 19px;
  top: 0;
  bottom: 0;
  width: 2px;
  background: linear-gradient(to bottom, var(--accent), transparent);
  opacity: 0.3;
}

.timeline-item {
  position: relative;
  padding-left: 56px;
  padding-bottom: 48px;
}

.timeline-item:last-child {
  padding-bottom: 0;
}

.timeline-dot {
  position: absolute;
  left: 12px;
  top: 4px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--bg-primary);
  border: 2px solid var(--accent);
  box-shadow: 0 0 12px rgba(99, 102, 241, 0.3);
}

.timeline-date {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--accent-light);
  margin-bottom: 8px;
  display: block;
}

.timeline-content h3 {
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 4px;
  letter-spacing: -0.01em;
}

.timeline-company {
  color: var(--text-muted);
  font-weight: 400;
}

.timeline-content p {
  color: var(--text-secondary);
  font-size: 0.95rem;
}

/* --- Speaking --- */
.speaking {
  background: var(--bg-secondary);
}

.speaking-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  margin-bottom: 48px;
}

.speaking-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 32px 24px;
  text-align: center;
  transition: all var(--transition);
}

.speaking-card:hover {
  border-color: var(--border-hover);
  background: var(--bg-card-hover);
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.speaking-icon {
  font-size: 2.2rem;
  margin-bottom: 16px;
}

.speaking-card h3 {
  font-size: 1.05rem;
  font-weight: 700;
  margin-bottom: 10px;
  letter-spacing: -0.01em;
}

.speaking-card p {
  font-size: 0.88rem;
  color: var(--text-secondary);
  line-height: 1.6;
}

.speaking-venues {
  text-align: center;
}

.venue-label {
  display: block;
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 12px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.venue-list {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
}

.venue-list span {
  background: var(--bg-card);
  border: 1px solid var(--border);
  color: var(--text-secondary);
  font-size: 0.82rem;
  font-weight: 500;
  padding: 6px 16px;
  border-radius: 100px;
  transition: all var(--transition);
}

.venue-list span:hover {
  border-color: var(--accent);
  color: var(--accent-light);
}

/* --- Book --- */
.book-section {
  background: var(--bg-primary);
  overflow: hidden;
}

.book-grid {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 64px;
  align-items: center;
}

.book-cover-area {
  display: flex;
  justify-content: center;
}

.book-cover {
  border-radius: 8px;
  overflow: hidden;
  box-shadow: var(--shadow-lg), 0 0 60px rgba(99, 102, 241, 0.1);
  border: 1px solid var(--border);
  line-height: 0;
}

.book-cover img {
  display: block;
  width: 100%;
  max-width: 320px;
  height: auto;
  transition: transform 0.5s ease;
}

.book-cover:hover img {
  transform: scale(1.03);
}

.book-info .section-tag {
  margin-bottom: 16px;
}

.book-info h2 {
  font-size: clamp(1.8rem, 3vw, 2.4rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.2;
  margin-bottom: 20px;
}

.book-desc {
  color: var(--text-secondary);
  font-size: 1.02rem;
  line-height: 1.8;
  margin-bottom: 12px;
}

.book-publisher {
  font-size: 0.88rem;
  color: var(--text-muted);
  margin-bottom: 28px;
}

.book-raves {
  display: flex;
  flex-direction: column;
  gap: 20px;
  margin-bottom: 32px;
}

.rave {
  border-left: 3px solid var(--accent);
  padding-left: 16px;
}

.rave p {
  font-size: 0.95rem;
  color: var(--text-secondary);
  font-style: italic;
  margin-bottom: 4px;
}

.rave cite {
  font-size: 0.82rem;
  color: var(--accent-light);
  font-style: normal;
  font-weight: 500;
}

.book-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

/* --- Newsletter --- */
.newsletter {
  background: var(--bg-secondary);
}

.newsletter-content {
  text-align: center;
  max-width: 680px;
  margin: 0 auto;
}

.newsletter-content .section-header {
  margin-bottom: 32px;
}

.newsletter-content h2 {
  font-size: clamp(2rem, 4vw, 2.8rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.2;
}

.newsletter-desc {
  color: var(--text-secondary);
  font-size: 1.02rem;
  line-height: 1.8;
  margin-bottom: 16px;
}

.newsletter-content .btn-large {
  margin-top: 32px;
}

/* --- Contact --- */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: start;
}

.contact-info p {
  color: var(--text-secondary);
  font-size: 1.02rem;
  margin-bottom: 24px;
}

.contact-email {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--accent-light);
  padding: 12px 24px;
  background: var(--accent-glow);
  border: 1px solid rgba(99, 102, 241, 0.2);
  border-radius: var(--radius-sm);
  margin-bottom: 32px;
  transition: all var(--transition);
}

.contact-email:hover {
  background: rgba(99, 102, 241, 0.2);
  border-color: var(--accent);
  color: var(--accent-light);
}

.contact-socials {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.social-link {
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--text-muted);
  padding: 6px 14px;
  border: 1px solid var(--border);
  border-radius: 100px;
  transition: all var(--transition);
}

.social-link:hover {
  border-color: var(--accent);
  color: var(--accent-light);
  background: var(--accent-glow);
}

/* --- Form --- */
.contact-form {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 36px;
}

.form-group {
  margin-bottom: 20px;
}

.form-group label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 8px;
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 12px 16px;
  background: var(--bg-primary);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text-primary);
  font-family: var(--font-sans);
  font-size: 0.95rem;
  transition: all var(--transition);
  outline: none;
}

.form-group input:focus,
.form-group textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-glow);
}

.form-group input::placeholder,
.form-group textarea::placeholder {
  color: var(--text-muted);
}

.form-group textarea {
  resize: vertical;
  min-height: 120px;
}

/* --- Footer --- */
.footer {
  border-top: 1px solid var(--border);
  padding: 48px 0;
}

.footer-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  text-align: center;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

.footer-logo {
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 1.25rem;
  color: var(--accent-light);
}

.footer-brand p {
  font-weight: 600;
  color: var(--text-secondary);
}

.footer-copy {
  font-size: 0.82rem;
  color: var(--text-muted);
}

.footer-links {
  display: flex;
  gap: 24px;
}

.footer-links a {
  font-size: 0.82rem;
  color: var(--text-muted);
  transition: color var(--transition);
}

.footer-links a:hover {
  color: var(--accent-light);
}

/* --- Animations --- */
.fade-in {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* --- Responsive --- */
@media (max-width: 1024px) {
  .speaking-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  
  .book-grid {
    grid-template-columns: 1fr;
    text-align: center;
  }
  
  .book-cover-area {
    order: -1;
  }
  
  .book-actions {
    justify-content: center;
  }
}

@media (max-width: 768px) {
  :root {
    --nav-height: 64px;
  }
  
  .nav-toggle {
    display: flex;
  }
  
  .nav-links {
    position: fixed;
    top: var(--nav-height);
    left: 0;
    right: 0;
    background: rgba(10, 10, 15, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    flex-direction: column;
    padding: 24px;
    gap: 4px;
    transform: translateY(-120%);
    opacity: 0;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    border-bottom: 1px solid var(--border);
  }
  
  .nav-links.open {
    transform: translateY(0);
    opacity: 1;
  }
  
  .nav-links a {
    display: block;
    padding: 12px 16px;
    font-size: 1rem;
  }
  
  .about-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }
  
  .about-highlights {
    order: -1;
  }

  .hero-photo {
    width: 130px;
    height: 130px;
  }
  
  .speaking-grid {
    grid-template-columns: 1fr;
  }
  
  .contact-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }
  
  .section {
    padding: 80px 0;
  }
  
  .hero-actions {
    flex-direction: column;
  }
  
  .hero-actions .btn {
    width: 100%;
  }
  
  .book-cover {
    width: 220px;
    height: 320px;
  }
}

@media (max-width: 480px) {
  .hero-name {
    font-size: 2.5rem;
  }
  
  .about-highlights {
    grid-template-columns: 1fr;
  }
  
  .contact-form {
    padding: 24px;
  }
  
  .hero-social {
    gap: 12px;
  }
  
  .footer-links {
    gap: 16px;
    flex-wrap: wrap;
    justify-content: center;
  }
}
