/*
Theme Name: Tom Leydiker
Theme URI: https://tomleydiker.com
Author: Tom Leydiker
Author URI: https://tomleydiker.com
Description: Professional executive portfolio theme for Tom Leydiker
Version: 1.0.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: tom-leydiker
*/

/* ========================================
   CSS Variables / Design System
======================================== */
:root {
  --background: hsl(45, 33%, 97%);
  --foreground: hsl(220, 30%, 20%);
  --card: hsl(0, 0%, 100%);
  --card-foreground: hsl(220, 30%, 20%);
  --primary: hsl(220, 40%, 25%);
  --primary-foreground: hsl(0, 0%, 100%);
  --secondary: hsl(45, 20%, 95%);
  --secondary-foreground: hsl(220, 30%, 25%);
  --muted: hsl(45, 15%, 92%);
  --muted-foreground: hsl(220, 15%, 45%);
  --accent: hsl(220, 50%, 45%);
  --accent-foreground: hsl(0, 0%, 100%);
  --border: hsl(220, 20%, 88%);
  --input: hsl(220, 20%, 88%);
  --ring: hsl(220, 40%, 25%);
  --radius: 0.75rem;
  --heading-font: 'Playfair Display', serif;
  --body-font: 'Inter', sans-serif;
  --shadow-card: 0 4px 20px -4px hsla(220, 30%, 20%, 0.08);
  --shadow-card-hover: 0 8px 30px -4px hsla(220, 30%, 20%, 0.12);
  --shadow-image: 0 20px 40px -12px hsla(220, 30%, 20%, 0.15);
}

.dark {
  --background: hsl(220, 25%, 10%);
  --foreground: hsl(45, 20%, 95%);
  --card: hsl(220, 25%, 14%);
  --card-foreground: hsl(45, 20%, 95%);
  --primary: hsl(45, 30%, 90%);
  --primary-foreground: hsl(220, 25%, 10%);
  --secondary: hsl(220, 20%, 18%);
  --secondary-foreground: hsl(45, 20%, 90%);
  --muted: hsl(220, 20%, 20%);
  --muted-foreground: hsl(45, 15%, 65%);
  --accent: hsl(220, 50%, 60%);
  --accent-foreground: hsl(0, 0%, 100%);
  --border: hsl(220, 20%, 22%);
  --input: hsl(220, 20%, 22%);
  --shadow-card: 0 4px 20px -4px hsla(0, 0%, 0%, 0.3);
  --shadow-card-hover: 0 8px 30px -4px hsla(0, 0%, 0%, 0.4);
  --shadow-image: 0 20px 40px -12px hsla(0, 0%, 0%, 0.4);
}

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--body-font);
  background-color: var(--background);
  color: var(--foreground);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--heading-font);
  font-weight: 600;
  line-height: 1.2;
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

ul, ol {
  list-style: none;
}

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
}

input, textarea {
  font-family: inherit;
  font-size: inherit;
}

/* ========================================
   Container
======================================== */
.container {
  width: 100%;
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* ========================================
   Elementor Compatibility
======================================== */
.elementor-page-content,
.elementor-canvas-content {
  width: 100%;
}

.elementor-page .site-header,
.elementor-page .site-footer {
  /* Ensure header/footer work with Elementor */
}

/* Full width sections for Elementor */
.elementor-section.elementor-section-boxed > .elementor-container {
  max-width: 1100px;
}

.elementor-section.elementor-section-full_width {
  max-width: 100%;
  padding: 0;
}

/* Elementor widgets inherit theme typography */
.elementor-widget-heading .elementor-heading-title {
  font-family: var(--heading-font);
}

.elementor-widget-text-editor {
  font-family: var(--body-font);
}

/* Ensure Elementor respects dark mode */
.dark .elementor-section {
  --e-global-color-primary: var(--foreground);
  --e-global-color-text: var(--foreground);
}

/* ========================================
   Header
======================================== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background-color: hsla(45, 33%, 97%, 0.8);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid hsla(220, 20%, 88%, 0.5);
}

.dark .site-header {
  background-color: hsla(220, 25%, 10%, 0.8);
  border-bottom-color: hsla(220, 20%, 22%, 0.5);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}

.site-logo {
  font-family: var(--heading-font);
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--foreground);
}

.site-logo:hover {
  color: var(--foreground);
}

.main-nav {
  display: none;
  align-items: center;
  gap: 2rem;
}

@media (min-width: 768px) {
  .main-nav {
    display: flex;
  }
}

.nav-link {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--muted-foreground);
  transition: color 0.2s ease;
}

.nav-link:hover {
  color: var(--foreground);
}

.dark-mode-toggle {
  padding: 0.5rem;
  border-radius: 0.5rem;
  color: var(--foreground);
  transition: background-color 0.2s ease;
}

.dark-mode-toggle:hover {
  background-color: var(--muted);
}

.dark-mode-toggle svg {
  width: 1rem;
  height: 1rem;
}

/* Mobile Menu Button */
.mobile-menu-btn {
  display: flex;
  padding: 0.5rem;
  border-radius: 0.5rem;
  color: var(--foreground);
}

@media (min-width: 768px) {
  .mobile-menu-btn {
    display: none;
  }
}

.mobile-menu-btn:hover {
  background-color: var(--muted);
}

/* Mobile Navigation */
.mobile-nav {
  display: none;
  padding: 1rem 0;
  border-top: 1px solid var(--border);
}

.mobile-nav.active {
  display: block;
}

@media (min-width: 768px) {
  .mobile-nav {
    display: none !important;
  }
}

.mobile-nav-link {
  display: block;
  padding: 0.75rem 1.5rem;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--muted-foreground);
  transition: color 0.2s ease;
}

.mobile-nav-link:hover {
  color: var(--foreground);
  background-color: var(--muted);
}

/* ========================================
   Hero Section
======================================== */
.hero-section {
  padding: 4rem 0;
}

@media (min-width: 768px) {
  .hero-section {
    padding: 6rem 0;
  }
}

@media (min-width: 1024px) {
  .hero-section {
    padding: 8rem 0;
  }
}

.hero-grid {
  display: grid;
  gap: 3rem;
  align-items: center;
}

@media (min-width: 768px) {
  .hero-grid {
    grid-template-columns: 1fr 1fr;
  }
}

.hero-content {
  order: 2;
}

@media (min-width: 768px) {
  .hero-content {
    order: 1;
  }
}

.hero-title {
  font-size: 2.5rem;
  color: var(--foreground);
  margin-bottom: 0.5rem;
}

@media (min-width: 768px) {
  .hero-title {
    font-size: 3rem;
  }
}

@media (min-width: 1024px) {
  .hero-title {
    font-size: 3.75rem;
  }
}

.hero-subtitle {
  font-size: 1.125rem;
  font-weight: 500;
  color: var(--accent);
  margin-bottom: 1rem;
}

@media (min-width: 768px) {
  .hero-subtitle {
    font-size: 1.25rem;
  }
}

.hero-description {
  font-size: 1.125rem;
  color: var(--muted-foreground);
  max-width: 28rem;
  margin-bottom: 1.5rem;
}

.hero-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.hero-socials {
  display: flex;
  gap: 0.75rem;
  padding-top: 0.5rem;
}

.social-link {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 1px solid var(--border);
  color: var(--muted-foreground);
  transition: background-color 0.2s ease, color 0.2s ease;
}

.social-link:hover {
  background-color: var(--muted);
  color: var(--foreground);
}

.social-link svg {
  width: 1.25rem;
  height: 1.25rem;
}

.hero-image-wrapper {
  order: 1;
  display: flex;
  justify-content: center;
}

@media (min-width: 768px) {
  .hero-image-wrapper {
    order: 2;
    justify-content: flex-end;
  }
}

.hero-image-container {
  position: relative;
}

.hero-image-bg {
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, hsla(220, 50%, 45%, 0.1), transparent);
  border-radius: 1.5rem;
  transform: rotate(3deg) scale(1.05);
}

.hero-image {
  position: relative;
  width: 18rem;
  height: 18rem;
  object-fit: cover;
  border-radius: 1.5rem;
  box-shadow: var(--shadow-image);
}

@media (min-width: 768px) {
  .hero-image {
    width: 20rem;
    height: 20rem;
  }
}

@media (min-width: 1024px) {
  .hero-image {
    width: 24rem;
    height: 24rem;
  }
}

/* ========================================
   Buttons
======================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.625rem 1.25rem;
  font-size: 0.875rem;
  font-weight: 500;
  border-radius: var(--radius);
  transition: all 0.2s ease;
}

.btn svg {
  width: 1rem;
  height: 1rem;
}

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

.btn-primary:hover {
  background-color: hsl(220, 40%, 20%);
}

.dark .btn-primary:hover {
  background-color: hsl(45, 30%, 80%);
}

.btn-outline {
  background-color: transparent;
  border: 1px solid var(--border);
  color: var(--foreground);
}

.btn-outline:hover {
  background-color: var(--muted);
}

/* ========================================
   Section Styles
======================================== */
.section {
  padding: 4rem 0;
}

@media (min-width: 768px) {
  .section {
    padding: 6rem 0;
  }
}

.section-heading {
  font-size: 1.875rem;
  font-weight: 600;
  color: var(--foreground);
  margin-bottom: 2rem;
}

@media (min-width: 768px) {
  .section-heading {
    font-size: 2.25rem;
    margin-bottom: 3rem;
  }
}

/* ========================================
   Cards
======================================== */
.card {
  background-color: var(--card);
  border-radius: 1rem;
  padding: 1.5rem;
  box-shadow: var(--shadow-card);
  transition: box-shadow 0.3s ease, transform 0.3s ease;
}

@media (min-width: 768px) {
  .card {
    padding: 2rem;
  }
}

.card:hover {
  box-shadow: var(--shadow-card-hover);
}

.card-title {
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--foreground);
  margin-bottom: 0.25rem;
}

.card-company {
  font-weight: 500;
  color: var(--accent);
  margin-bottom: 0.5rem;
}

.card-period {
  font-size: 0.875rem;
  color: var(--muted-foreground);
  margin-bottom: 1rem;
}

.card-description {
  color: var(--muted-foreground);
  line-height: 1.6;
}

/* ========================================
   Status Badge
======================================== */
.status-badge {
  display: inline-flex;
  align-items: center;
  padding: 0.25rem 0.75rem;
  font-size: 0.75rem;
  font-weight: 500;
  border-radius: 9999px;
}

.status-badge-active {
  background-color: hsl(142, 76%, 94%);
  color: hsl(142, 71%, 29%);
}

.dark .status-badge-active {
  background-color: hsla(142, 71%, 29%, 0.3);
  color: hsl(142, 71%, 60%);
}

/* ========================================
   About Section
======================================== */
.about-content {
  max-width: 48rem;
}

.about-content p {
  color: var(--muted-foreground);
  line-height: 1.8;
  margin-bottom: 1.5rem;
}

.about-content p:last-child {
  margin-bottom: 0;
}

/* ========================================
   Experience Section
======================================== */
.experience-list {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.experience-card {
  position: relative;
}

.experience-badge {
  position: absolute;
  top: 1.5rem;
  right: 1.5rem;
}

@media (min-width: 768px) {
  .experience-badge {
    top: 2rem;
    right: 2rem;
  }
}

.experience-content {
  padding-right: 5rem;
}

@media (min-width: 768px) {
  .experience-content {
    padding-right: 6rem;
  }
}

/* ========================================
   Ventures Section
======================================== */
.ventures-grid {
  display: grid;
  gap: 1.5rem;
}

@media (min-width: 768px) {
  .ventures-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .ventures-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.venture-card {
  cursor: pointer;
}

.venture-badge {
  margin-bottom: 1rem;
}

.venture-title {
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--foreground);
  margin-bottom: 0.25rem;
  margin-top: 0.5rem;
}

.venture-type {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--accent);
  margin-bottom: 0.75rem;
}

.venture-description {
  font-size: 0.875rem;
  color: var(--muted-foreground);
  margin-bottom: 1rem;
}

.venture-link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--accent);
  transition: gap 0.2s ease;
}

.venture-card:hover .venture-link {
  gap: 0.75rem;
}

.venture-link svg {
  width: 1rem;
  height: 1rem;
}

/* ========================================
   Focus Section
======================================== */
.focus-grid {
  display: grid;
  gap: 1.5rem;
}

@media (min-width: 768px) {
  .focus-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

.focus-title {
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--foreground);
  margin-bottom: 1.5rem;
}

.focus-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.focus-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  color: var(--muted-foreground);
}

.focus-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background-color: var(--accent);
  flex-shrink: 0;
}

/* ========================================
   Contact Section
======================================== */
.contact-grid {
  display: grid;
  gap: 3rem;
}

@media (min-width: 768px) {
  .contact-grid {
    grid-template-columns: 1fr 1fr;
  }
}

.contact-intro p {
  font-size: 1.125rem;
  color: var(--muted-foreground);
  margin-bottom: 1.5rem;
}

.contact-email {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 500;
  color: var(--accent);
  transition: text-decoration 0.2s ease;
}

.contact-email:hover {
  text-decoration: underline;
}

.contact-email svg {
  width: 1.25rem;
  height: 1.25rem;
}

.contact-form-title {
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--foreground);
  margin-bottom: 1.5rem;
}

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

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

.form-label {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--foreground);
}

.form-input,
.form-textarea {
  padding: 0.625rem 0.875rem;
  font-size: 0.875rem;
  background-color: var(--background);
  border: 1px solid var(--input);
  border-radius: var(--radius);
  color: var(--foreground);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.form-input:focus,
.form-textarea:focus {
  outline: none;
  border-color: var(--ring);
  box-shadow: 0 0 0 2px hsla(220, 40%, 25%, 0.1);
}

.form-input::placeholder,
.form-textarea::placeholder {
  color: var(--muted-foreground);
}

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

.form-submit {
  width: 100%;
}

/* ========================================
   Footer
======================================== */
.site-footer {
  border-top: 1px solid var(--border);
  padding: 2rem 0;
}

.footer-text {
  text-align: center;
  font-size: 0.875rem;
  color: var(--muted-foreground);
}

/* ========================================
   CV Page
======================================== */
.cv-back-link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--muted-foreground);
  margin-bottom: 2rem;
  transition: color 0.2s ease;
}

.cv-back-link:hover {
  color: var(--foreground);
}

.cv-back-link svg {
  width: 1rem;
  height: 1rem;
}

.cv-header {
  margin-bottom: 2rem;
}

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

@media (min-width: 768px) {
  .cv-header-content {
    flex-direction: row;
    align-items: flex-start;
  }
}

.cv-photo {
  width: 8rem;
  height: 8rem;
  border-radius: 1rem;
  object-fit: cover;
  box-shadow: var(--shadow-card);
}

.cv-header-text {
  text-align: center;
  flex: 1;
}

@media (min-width: 768px) {
  .cv-header-text {
    text-align: left;
  }
}

.cv-name {
  font-size: 1.875rem;
  color: var(--foreground);
  margin-bottom: 0.5rem;
}

@media (min-width: 768px) {
  .cv-name {
    font-size: 2.25rem;
  }
}

.cv-title {
  font-size: 1.125rem;
  font-weight: 500;
  color: var(--accent);
  margin-bottom: 0.5rem;
}

.cv-tagline {
  color: var(--muted-foreground);
  margin-bottom: 1rem;
}

.cv-grid {
  display: grid;
  gap: 2rem;
}

@media (min-width: 1024px) {
  .cv-grid {
    grid-template-columns: 2fr 1fr;
  }
}

.cv-main {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.cv-sidebar {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.cv-section-title {
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--foreground);
  margin-bottom: 1.5rem;
}

.cv-experience-list {
  display: flex;
  flex-direction: column;
}

.cv-experience-item {
  padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--border);
}

.cv-experience-item:last-child {
  padding-bottom: 0;
  border-bottom: none;
}

.cv-experience-item + .cv-experience-item {
  padding-top: 1.5rem;
}

.cv-experience-header {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: flex-start;
  gap: 0.5rem;
  margin-bottom: 0.25rem;
}

.cv-experience-title {
  font-weight: 600;
  color: var(--foreground);
}

.cv-experience-period {
  font-size: 0.875rem;
  color: var(--muted-foreground);
}

.cv-experience-company {
  font-weight: 500;
  color: var(--accent);
  margin-bottom: 0.5rem;
}

.cv-experience-desc {
  font-size: 0.875rem;
  color: var(--muted-foreground);
}

.cv-about p {
  font-size: 0.875rem;
  color: var(--muted-foreground);
  line-height: 1.7;
  margin-bottom: 1rem;
}

.cv-about p:last-child {
  margin-bottom: 0;
}

.cv-sidebar-title {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--foreground);
  margin-bottom: 1rem;
}

.cv-sidebar-title svg {
  width: 1.25rem;
  height: 1.25rem;
  color: var(--accent);
}

.cv-education-degree {
  font-weight: 600;
  color: var(--foreground);
}

.cv-education-school {
  font-size: 0.875rem;
  color: var(--muted-foreground);
}

.cv-list {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.cv-list-item {
  font-size: 0.875rem;
  color: var(--muted-foreground);
}

/* ========================================
   Utility Classes
======================================== */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border-width: 0;
}
