﻿/* css/style.css | Custom stylesheet for CV-SPA project */
/* Bootstrap Integration Notes:
 * - This project uses Bootstrap 5.3.3 from CDN (https://cdn.jsdelivr.net/npm/bootstrap@5.3.3/)
 * - Bootstrap provides: responsive grid system (container, row, col classes), navbar components, utility classes
 * - Bootstrap Documentation: https://getbootstrap.com/docs/5.3/getting-started/introduction/
 * - Custom CSS below extends Bootstrap with theme variables, dark mode, and project-specific styling
 * - Key Bootstrap components used: navbar (with collapse), grid (row/col), utilities (spacing, flex, display)
 */

/* === CSS CUSTOM PROPERTIES (VARIABLES) === */
/* Root variables define the color palette and spacing system used throughout the site */
:root {
  /* Professional CV Color Scheme - Orange + White + Dark Gray */
  --bg: #353535;
  --bg-secondary: #4a4a4a;
  --bg-alternate: #5a5a5a;
  --text: #FFFFFF;
  --text-secondary: #e0e0e0;
  --text-muted: #b0b0b0;
  --accent: #4a4a4a;
  --highlight: #FF6B01;
  --highlight-bright: #ff8534;
  --highlight-dark: #e55e00;
  --navy: #353535;
  --card-bg: #4a4a4a;
  --surface-border: #5a5a5a;
  --link-hover: #ff8534;
  --bg-overlay: linear-gradient(135deg, #353535 0%, #4a4a4a 100%);
  --texture-overlay: radial-gradient(ellipse at 50% 0%, rgba(255, 107, 1, 0.08) 0%, transparent 50%);
  --texture-opacity: 0.5;
  --card-shadow: 0 1px 3px rgba(0, 0, 0, 0.3), 0 1px 2px rgba(0, 0, 0, 0.2);
  --card-shadow-hover: 0 4px 8px rgba(0, 0, 0, 0.4), 0 2px 4px rgba(0, 0, 0, 0.3);
  --button-bg: #FF6B01;
  --button-bg-hover: #ff8534;
  --button-text: #FFFFFF;
  --success: #10b981;
  --warning: #f59e0b;
  --error: #ef4444;
  
  /* Spacing System - 8px grid */
  --space-xs: 8px;
  --space-sm: 16px;
  --space-md: 24px;
  --space-lg: 32px;
  --space-xl: 40px;
  --space-2xl: 80px;
  --space-3xl: 100px;
}

/* === DARK MODE THEME OVERRIDES === */
/* Applied when body has 'dark' class - provides light theme alternative */
body.dark {
  /* Professional CV Color Scheme - Light Theme (Opposite) */
  --bg: #FFFFFF;
  --bg-secondary: #f8fafc;
  --bg-alternate: #f1f5f9;
  --text: #000000;
  --text-secondary: #000000;
  --text-muted: #000000;
  --accent: #f8fafc;
  --highlight: #FF6B01;
  --highlight-bright: #ff8534;
  --highlight-dark: #e55e00;
  --navy: #000000;
  --card-bg: #FFFFFF;
  --surface-border: #e2e8f0;
  --link-hover: #ff8534;
  --bg-overlay: linear-gradient(135deg, #FFFFFF 0%, #f8fafc 100%);
  --texture-overlay: radial-gradient(ellipse at 50% 0%, rgba(255, 107, 1, 0.05) 0%, transparent 50%);
  --texture-opacity: 0.5;
  --card-shadow: 0 1px 3px rgba(0, 0, 0, 0.08), 0 1px 2px rgba(0, 0, 0, 0.04);
  --card-shadow-hover: 0 4px 8px rgba(0, 0, 0, 0.12), 0 2px 4px rgba(0, 0, 0, 0.08);
  --button-bg: #FF6B01;
  --button-bg-hover: #ff8534;
  --button-text: #FFFFFF;
  --success: #10b981;
  --warning: #f59e0b;
  --error: #ef4444;
}

/* === BASE ELEMENT RESET === */
/* Universal box-sizing and margin/padding reset for consistent layout */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

/* === BODY STYLING === */
/* Main body container with theme colors, gradients, and smooth transitions */
body {
  position: relative;
  min-height: 100vh;
  background-color: var(--bg);
  background-image: var(--bg-overlay);
  color: var(--text);
  font-family: Arial, Helvetica, sans-serif;
  line-height: 1.6;
  font-size: 16px;
  font-weight: 400;
  transition: background-color 0.3s ease, color 0.3s ease;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* === PAGE LOADING STATES === */
/* Smooth fade-in effect when page loads */
body.page-loading {
  opacity: 0;
}

body.page-loaded {
  opacity: 1;
  transition: opacity 0.4s ease;
}

/* === TEXTURE OVERLAY === */
/* Subtle gradient texture applied via pseudo-element for visual depth */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background: var(--texture-overlay);
  background-size: cover;
  opacity: var(--texture-opacity);
  z-index: 0;
}

/* === ANIMATION KEYFRAMES === */
/* Reusable animations for page elements - fade, slide, scale effects */
/* SMOOTH PAGE LOAD ANIMATIONS */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

@keyframes slideInFromLeft {
  from {
    opacity: 0;
    transform: translateX(-30px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes scaleIn {
  from {
    opacity: 0;
    transform: scale(0.95);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

/* === SCROLL REVEAL ANIMATION === */
/* Elements with .reveal-on-scroll class fade in when scrolled into view (triggered by JS) */
.reveal-on-scroll {
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.6s ease;
}

.reveal-on-scroll.revealed {
  opacity: 1;
  transform: translateY(0);
}

/* === PAGE LOAD ELEMENT ANIMATIONS === */
/* Staggered animation delays create a cascading reveal effect on page load */
/* Page load animations */
.page-shell {
  animation: fadeIn 0.5s ease;
  padding: var(--space-3xl) 0;
}

section {
  padding: var(--space-3xl) 0;
  margin-bottom: var(--space-2xl);
}

.nav {
  animation: fadeInUp 0.6s ease;
}

.card {
  animation: fadeInUp 0.7s ease backwards;
}

.card:nth-child(1) {
  animation-delay: 0.1s;
}

.card:nth-child(2) {
  animation-delay: 0.2s;
}

.card:nth-child(3) {
  animation-delay: 0.3s;
}

.card:nth-child(4) {
  animation-delay: 0.4s;
}

.card:nth-child(5) {
  animation-delay: 0.5s;
}

.card:nth-child(6) {
  animation-delay: 0.6s;
}

.profile-photo {
  animation: scaleIn 0.8s ease;
}

header.mb-4 {
  animation: slideInFromLeft 0.7s ease;
}

/* === NAVIGATION BAR STYLING === */
/* Custom navbar extending Bootstrap's navbar component with glassmorphism effect */
/* Bootstrap navbar component enhanced with backdrop-filter and custom styling */
/* IMPROVED NAVIGATION */
.nav {
  background: var(--accent);
  -webkit-backdrop-filter: blur(16px);
  backdrop-filter: blur(16px);
  padding: 0.75rem 1.25rem;
  margin: 1rem 1.25rem 0;
  border-radius: 12px;
  position: sticky;
  top: 1rem;
  z-index: 1020;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  border: 1px solid var(--surface-border);
}

/* === NAVBAR BRAND (LOGO) === */
/* Navbar brand styling - Bootstrap .navbar-brand class extended */
.nav .navbar-brand {
  font-weight: 700;
  font-size: 1.125rem;
  color: var(--highlight) !important;
  letter-spacing: -0.01em;
}

/* === NAVBAR LINKS === */
/* Bootstrap .nav-link styling with hover effects and active state indicators */
.nav .nav-link {
  font-weight: 500;
  font-size: 0.875rem;
  color: var(--text-secondary) !important;
  padding: 0.5rem 0.875rem !important;
  margin: 0 0.125rem;
  border-radius: 6px;
  transition: all 0.2s ease;
  border: 1px solid transparent;
  position: relative;
}

/* === NAVBAR LINK UNDERLINE EFFECT === */
/* Animated underline that appears on hover and for active links */
.nav .nav-link::after {
  content: '';
  position: absolute;
  bottom: 6px;
  left: 0.875rem;
  right: 0.875rem;
  height: 2px;
  background-color: var(--highlight);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.3s ease;
}

/* === NAVBAR LINK STATES === */
/* Hover and active states for navigation links */
.nav .nav-link:hover::after,
.nav .nav-link.active::after {
  transform: scaleX(1);
}

.nav .nav-link:hover,
.nav .nav-link:focus {
  background: rgba(255, 255, 255, 0.08);
  border-color: var(--highlight);
  color: var(--highlight) !important;
  transform: translateY(-1px);
}

.nav .nav-link.active {
  background: var(--highlight);
  color: var(--bg) !important;
  border-color: var(--highlight);
  font-weight: 600;
  box-shadow: 0 2px 8px rgba(59, 130, 246, 0.3);
}

body.dark .nav .nav-link.active {
  box-shadow: 0 2px 8px rgba(139, 92, 246, 0.3);
}

/* === TYPOGRAPHY === */
/* Heading styles with responsive sizing and custom font families */
/* IMPROVED TYPOGRAPHY - Professional Hierarchy */
h1, h2, h3, h4, h5, h6 {
  font-family: Calibri, 'Trebuchet MS', sans-serif;
  color: #FFFFFF;
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: -0.01em;
  margin-bottom: var(--space-md);
}

/* === DARK MODE HEADING OVERRIDES === */
/* Headings get highlight color in dark mode for better visibility */
body.dark h1, 
body.dark h2, 
body.dark h3, 
body.dark h4, 
body.dark h5, 
body.dark h6 {
  color: var(--highlight);
}

/* === DISPLAY HEADING SIZES === */
/* Bootstrap display classes with custom sizing */
.display-5 {
  font-size: 48px !important;
  font-weight: 700;
  margin-bottom: var(--space-lg);
}

.display-6 {
  font-size: 40px !important;
  font-weight: 700;
  margin-bottom: var(--space-lg);
}

h1 {
  font-size: 48px;
  margin-bottom: var(--space-lg);
}

h2 {
  font-size: 32px;
  margin-bottom: var(--space-md);
}

h3 {
  font-size: 24px;
  margin-bottom: var(--space-sm);
}

h4 {
  font-size: 20px;
  margin-bottom: var(--space-sm);
}

/* === LEAD PARAGRAPH STYLING === */
/* Bootstrap .lead class for intro paragraphs */
.lead {
  font-size: 18px;
  font-weight: 400;
  line-height: 1.6;
  margin-bottom: var(--space-md);
  color: var(--text-secondary);
}

/* === PAGE SHELL CONTAINER === */
/* Main content wrapper - works with Bootstrap container classes */
/* IMPROVED CARD DESIGN WITH BETTER SPACING */
.page-shell {
  padding: var(--space-2xl) var(--space-md) var(--space-2xl);
  position: relative;
  z-index: 1;
  max-width: 1200px;
  margin: 0 auto;
}

/* === CARD COMPONENT === */
/* Custom card styling extending Bootstrap's card component */
/* Cards use flexbox for equal height in Bootstrap grid layouts */
.card {
  background: var(--card-bg);
  border: 1px solid var(--surface-border);
  border-radius: 8px;
  padding: var(--space-md) var(--space-lg);
  box-shadow: var(--card-shadow);
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
  height: 100%;
  display: flex;
  flex-direction: column;
  min-height: 160px;
}

/* === CARD TOP BORDER ACCENT === */
/* Decorative top border on cards for visual hierarchy */
.card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: var(--highlight);
}

/* === CARD HOVER EFFECTS === */
/* Lift and shadow effects on hover for interactivity */
.card:hover {
  transform: translateY(-5px);
  box-shadow: var(--card-shadow-hover);
  border-color: var(--highlight);
}

/* === DARK MODE CARD HOVER === */
/* Enhanced shadow in dark mode */
body.dark .card:hover {
  box-shadow: 0 8px 24px rgba(255, 107, 1, 0.3), 0 4px 12px rgba(255, 107, 1, 0.2);
}

/* === CARD FOCUS STATE === */
/* Accessibility: visible focus indicator for keyboard navigation */
.card:focus-within {
  outline: 2px solid var(--highlight);
  outline-offset: 2px;
  transform: translateY(-5px);
}

/* === CARD TEXT STYLING === */
/* Headings and text inside cards */
.card h2, .card h3, .card h4 {
  color: #FFFFFF;
  margin-bottom: var(--space-sm);
  font-size: 20px;
  font-weight: 600;
  font-family: Calibri, 'Trebuchet MS', sans-serif;
}

/* === CARD TEXT IN DARK MODE === */
body.dark .card h2,
body.dark .card h3,
body.dark .card h4 {
  color: #353535;
}

/* === CARD PARAGRAPH AND LIST STYLING === */
.card p, .card li {
  color: var(--text-secondary);
  font-size: 15px;
  line-height: 1.6;
  margin-bottom: var(--space-sm);
}

.card ul, .card ol {
  margin-left: var(--space-md);
  margin-bottom: var(--space-sm);
}

.card li {
  margin-bottom: var(--space-xs);
  padding-left: var(--space-xs);
}

/* === CARD SUBTITLE === */
.card-subtitle {
  font-size: 14px;
  color: var(--text-muted);
  margin-bottom: var(--space-sm);
  font-weight: 500;
}

/* === PROFILE PHOTO === */
/* Circular profile image with border and hover effect */
/* PERFECTLY ROUND PHOTO - NO BLACK ARTIFACTS */
.profile-photo {
  width: 200px;
  height: 200px;
  border-radius: 50%;
  border: 4px solid var(--highlight);
  box-shadow: 0 8px 24px rgba(34, 211, 238, 0.3);
  object-fit: cover;
  background: var(--card-bg);
  display: block;
  margin: 0 auto;
  transition: transform 0.3s ease;
  overflow: hidden;
}

.profile-photo:hover {
  transform: scale(1.1);
}

/* === PROJECT IMAGES === */
/* Images within project cards and general cards */
/* Project Images */
.project-card img,
.card img {
  width: 100%;
  height: auto;
  border-radius: 8px;
  transition: transform 0.3s ease;
  object-fit: cover;
}

.project-card:hover img,
.card:hover img {
  transform: scale(1.1);
}

/* === BUTTON STYLING === */
/* Primary contact button with hover and focus states */
/* IMPROVED BUTTONS - Professional CTA Style */
.btn-contact {
  background: var(--button-bg);
  color: var(--button-text);
  border: 2px solid var(--button-bg);
  padding: 12px 30px;
  font-size: 16px;
  font-weight: 600;
  border-radius: 6px;
  transition: all 0.3s ease;
  text-decoration: none;
  display: inline-block;
  box-shadow: 0 2px 8px rgba(34, 211, 238, 0.2);
  min-height: 44px;
  line-height: 1.5;
}

.btn-contact:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(34, 211, 238, 0.3);
  background: var(--button-bg-hover);
  border-color: var(--button-bg-hover);
}

.btn-contact:active {
  transform: translateY(0);
  box-shadow: 0 1px 4px rgba(34, 211, 238, 0.2);
}

.btn-contact:focus {
  outline: 2px solid var(--highlight);
  outline-offset: 2px;
}

/* === SECONDARY BUTTON === */
/* Secondary Button Style */
.btn-secondary {
  background: transparent;
  color: var(--highlight);
  border: 2px solid var(--highlight);
  padding: 12px 30px;
  font-size: 16px;
  font-weight: 600;
  border-radius: 6px;
  transition: all 0.3s ease;
  text-decoration: none;
  display: inline-block;
  min-height: 44px;
  line-height: 1.5;
}

.btn-secondary:hover {
  background: var(--highlight);
  color: var(--button-text);
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(34, 211, 238, 0.3);
}

/* === THEME TOGGLE SWITCH === */
/* Custom theme toggle switch with smooth transitions */
/* THEME TOGGLE IMPROVEMENTS */
.theme-switch {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 0.625rem;
  background: rgba(255, 255, 255, 0.08);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  border: 1px solid var(--surface-border);
  padding: 0.375rem 0.875rem;
  border-radius: 50px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.theme-switch:hover {
  background: rgba(255, 255, 255, 0.12);
  border-color: var(--highlight);
}

body.dark .theme-switch {
  background: rgba(255, 255, 255, 0.06);
  border-color: var(--surface-border);
}

body.dark .theme-switch:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: var(--highlight);
}

.theme-switch input[type="checkbox"] {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
}

.slider {
  position: relative;
  display: inline-block;
  width: 42px;
  height: 22px;
  background: rgba(255, 255, 255, 0.15);
  border-radius: 50px;
  transition: all 0.3s ease;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.slider::before {
  content: "";
  position: absolute;
  height: 16px;
  width: 16px;
  left: 2px;
  top: 2px;
  background: var(--highlight);
  border-radius: 50%;
  transition: all 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.2);
}

.theme-switch input:checked + .slider {
  background: rgba(139, 92, 246, 0.3);
  border-color: var(--highlight);
}

.theme-switch input:checked + .slider::before {
  transform: translateX(20px);
  background: var(--highlight);
  box-shadow: 0 1px 6px rgba(139, 92, 246, 0.4);
}

.theme-switch input:focus + .slider {
  outline: 2px solid var(--highlight);
  outline-offset: 1px;
}

.mode-label {
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--text-secondary);
  transition: color 0.2s ease;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;
  white-space: nowrap;
}

/* === THEME LABEL TRANSITION STATE === */
.mode-label.is-transitioning {
  opacity: 0.5;
}

/* === BOOTSTRAP GRID SPACING === */
/* Custom grid spacing overrides for Bootstrap .row and .col classes */
/* GRID SPACING IMPROVEMENTS - FORCE PROPER GAPS */
.row.g-4 {
  --bs-gutter-x: 4rem;
  --bs-gutter-y: 4rem;
  margin-bottom: 1.5rem;
  display: flex;
  flex-wrap: wrap;
  gap: 4rem 3rem;
}

/* === BOOTSTRAP ROW-COLS RESPONSIVE === */
/* Perfect 3-column layout with consistent spacing */
/* Bootstrap responsive column classes extended */
.row-cols-1 > * {
  flex: 0 0 auto;
  width: 100%;
  margin-bottom: 0;
}

@media (min-width: 768px) {
  .row-cols-md-2 > * {
    flex: 0 0 auto;
    width: calc(50% - 1.5rem);
  }
  
  .row.g-4 {
    gap: 3rem 2.5rem;
  }
}

@media (min-width: 1200px) {
  .row-cols-xl-3 > * {
    flex: 0 0 auto;
    width: calc(33.333% - 2rem);
  }
  
  .row.g-4 {
    gap: 4rem 3rem;
  }
}

/* === BOOTSTRAP HEIGHT UTILITY === */
/* Ensure cards stretch to equal height */
/* Bootstrap .h-100 class ensures equal height cards in flex layouts */
.h-100 {
  height: 100% !important;
  display: flex;
  flex-direction: column;
}

/* === PROJECT CARD SPECIFIC STYLING === */
/* Additional spacing fix for project cards */
.project-card {
  text-align: center;
  margin: 0 !important;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  height: 100%;
}

.project-card h2,
.project-card h3,
.project-card h4 {
  font-size: 20px;
  margin-bottom: var(--space-sm);
}

.project-card p {
  font-size: 15px;
  line-height: 1.6;
  margin-bottom: var(--space-md);
}

.project-card a {
  display: inline-block;
  background: var(--button-bg);
  color: var(--button-text);
  padding: 10px 24px;
  border-radius: 6px;
  font-weight: 600;
  font-size: 15px;
  text-decoration: none;
  transition: all 0.3s ease;
  margin-top: auto;
  border: 2px solid transparent;
  box-shadow: 0 2px 6px rgba(34, 211, 238, 0.2);
  min-height: 44px;
  line-height: 1.5;
}

.project-card a:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(34, 211, 238, 0.3);
  background: var(--button-bg-hover);
}

.project-card a:active {
  transform: translateY(0);
  box-shadow: 0 1px 4px rgba(34, 211, 238, 0.2);
}

.project-card a:focus {
  outline: 2px solid var(--highlight);
  outline-offset: 2px;
}

/* === SCROLL TO TOP BUTTON === */
/* Fixed position button that appears when scrolling down */
/* SCROLL TO TOP BUTTON */
.to-top {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  background: var(--button-bg);
  color: var(--button-text);
  border: 1px solid var(--highlight);
  border-radius: 50%;
  width: 48px;
  height: 48px;
  font-size: 1.25rem;
  font-weight: 600;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
  transition: all 0.2s ease;
  cursor: pointer;
  z-index: 1000;
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
}

.to-top.visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.to-top:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.25);
  background: var(--button-bg-hover);
}

.to-top:focus {
  outline: 2px solid var(--highlight);
  outline-offset: 2px;
}

.to-top-icon {
  font-size: 1.25rem;
  display: inline-block;
  transition: transform 0.2s ease;
}

.to-top:hover .to-top-icon {
  transform: translateY(-2px);
}

.to-top-text {
  display: none;
}

@media (max-width: 768px) {
  .to-top {
    bottom: 1rem;
    right: 1rem;
    width: 44px;
    height: 44px;
  }
}

/* === RESPONSIVE BREAKPOINTS === */
/* Media queries for Bootstrap breakpoints (lg, md, sm, xs) */
/* RESPONSIVE DESIGN */
@media (max-width: 1200px) {
  .container-xxl {
    max-width: 1140px;
  }
}

/* === TABLET BREAKPOINT (992px and below) === */
@media (max-width: 992px) {
  .page-shell {
    padding: 1.25rem 1.5rem 2.5rem;
  }
  
  .display-5 {
    font-size: 1.75rem !important;
  }
  
  .display-6 {
    font-size: 1.5rem !important;
  }
  
  .card {
    padding: 1rem 1.25rem;
  }
}

/* === MOBILE BREAKPOINT (768px and below) === */
@media (max-width: 768px) {
  body {
    font-size: 0.875rem;
  }
  
  .nav {
    margin: 0.75rem 0.875rem 0;
    padding: 0.625rem 1rem;
  }
  
  .page-shell {
    padding: 1rem 1.25rem 2rem;
  }
  
  .display-5 {
    font-size: 1.5rem !important;
  }
  
  .display-6 {
    font-size: 1.375rem !important;
  }
  
  h1 {
    font-size: 1.5rem;
  }
  
  h2 {
    font-size: 1.25rem;
  }
  
  .card {
    padding: 0.75rem 0.875rem;
    min-height: 120px;
  }
  
  .profile-photo {
    width: 150px;
    height: 150px;
  }
  
  .row.g-4 {
    gap: 1.5rem;
  }
  
  /* Ensure all touch targets are minimum 44px */
  .btn,
  .nav-link,
  button {
    min-height: 44px;
    min-width: 44px;
  }
}

/* === SMALL MOBILE BREAKPOINT (576px and below) === */
@media (max-width: 576px) {
  .page-shell {
    padding: 0.75rem 1rem 1.5rem;
  }
  
  .nav {
    margin: 0.625rem 0.75rem 0;
    border-radius: 10px;
  }
  
  .display-5 {
    font-size: 1.375rem !important;
  }
  
  .display-6 {
    font-size: 1.25rem !important;
  }
  
  .card {
    padding: 0.625rem 0.75rem;
    border-radius: 8px;
    min-height: 110px;
  }
  
  .profile-photo {
    width: 120px;
    height: 120px;
  }
  
  body {
    font-size: 0.9375rem;
  }
  
  h1 {
    font-size: 1.5rem;
  }
  
  h2 {
    font-size: 1.25rem;
  }
  
  .btn-contact {
    padding: 0.5rem 1rem;
    font-size: 0.8125rem;
    width: 100%;
    text-align: center;
    margin-bottom: 0.5rem;
  }
  
  .nav .nav-link {
    padding: 0.5rem 0.75rem !important;
    font-size: 0.875rem;
    margin: 0.125rem 0;
  }
  
  .theme-switch {
    padding: 0.5rem 0.75rem;
    width: 100%;
    justify-content: center;
  }
  
  .row.g-4 {
    gap: 1.25rem;
  }
}

/* === TEXT UTILITIES === */
/* Bootstrap text utility classes extended */
/* TEXT CONTRAST FIXES */
.text-muted {
  color: var(--text-muted) !important;
  font-size: 0.875rem;
}

/* === ACCESSIBILITY === */
/* Skip link and focus improvements for keyboard navigation */
/* SKIP TO CONTENT LINK - Accessibility */
.skip-to-content {
  position: fixed;
  top: -200px;
  left: 1rem;
  background: var(--highlight);
  color: var(--bg);
  padding: 0.75rem 1.5rem;
  border-radius: 8px;
  font-weight: 600;
  text-decoration: none;
  z-index: 10000;
  transition: top 0.3s ease;
  opacity: 0;
}

.skip-to-content:focus {
  top: 1rem;
  opacity: 1;
  outline: 3px solid var(--text-primary);
  outline-offset: 2px;
}

/* === FOCUS VISIBLE === */
/* Modern focus indicator for all interactive elements */
/* FOCUS VISIBLE IMPROVEMENTS */
*:focus-visible {
  outline: 2px solid var(--highlight);
  outline-offset: 2px;
  transition: outline 0.15s ease;
}

/* === LINK STYLING === */
/* LINK IMPROVEMENTS */
a {
  color: var(--highlight);
  text-decoration: none;
  transition: all 0.2s ease;
}

a:hover {
  color: var(--link-hover);
}

body.dark a:hover {
  color: #000000 !important;
}

a:focus {
  outline: 2px solid var(--highlight);
  outline-offset: 1px;
}

/* === LOADING ANIMATION === */
/* LOADING STATE */
@keyframes pulse {
  0%, 100% {
    opacity: 1;
  }
  50% {
    opacity: 0.5;
  }
}

.loading {
  animation: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

/* === SMOOTH SCROLL === */
/* SMOOTH SCROLL */
html {
  scroll-behavior: smooth;
}

/* === ACCESSIBILITY: REDUCED MOTION === */
/* Disable smooth scroll for users who prefer reduced motion */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* === HEADER VISIBILITY === */
/* HEADLINE VISIBILITY FIX */
header.mb-4 {
  background: var(--card-bg);
  padding: 1rem 1.25rem;
  border-radius: 10px;
  margin-bottom: 6rem !important;
  border: 1px solid var(--surface-border);
  position: relative;
  z-index: 10;
}

header.mb-4 h1 {
  margin-bottom: 0.375rem;
}

header.mb-4 .text-muted {
  font-size: 0.875rem;
  opacity: 0.9;
}

/* === DARK MODE CARD EFFECTS === */
/* METALLIC PURPLE EFFECT FOR DARK MODE */
body.dark .card {
  background: var(--card-bg);
  position: relative;
  overflow: hidden;
  border-color: var(--surface-border);
}

body.dark .card::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(
    135deg,
    transparent 0%,
    rgba(255, 255, 255, 0.02) 50%,
    transparent 100%
  );
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
}

body.dark .card:hover::after {
  opacity: 1;
}

body.dark .nav {
  background: var(--accent);
  border: 1px solid var(--surface-border);
}

/* === PAGE-SPECIFIC LAYOUTS === */
/* COVER LETTER LAYOUT OPTIMIZATION */
body[data-page="cover-letter"] .cover-letter-row {
  gap: 2rem !important;
  align-items: flex-start;
  display: flex;
  flex-wrap: wrap;
}

body[data-page="cover-letter"] .cover-letter-row > * {
  flex: 0 0 auto;
}

body[data-page="cover-letter"] aside .card {
  display: flex;
  flex-direction: column;
  height: auto !important;
}

body[data-page="cover-letter"] article .card {
  height: auto !important;
}

body[data-page="cover-letter"] .profile-photo {
  max-width: 250px;
  height: auto;
  display: block;
  margin-left: auto;
  margin-right: auto;
}

@media (min-width: 768px) {
  body[data-page="cover-letter"] .cover-letter-row {
    flex-wrap: nowrap;
  }
  
  body[data-page="cover-letter"] .col-md-4 {
    flex: 0 0 33.333333%;
    max-width: 33.333333%;
  }
  
  body[data-page="cover-letter"] .col-md-8 {
    flex: 0 0 66.666667%;
    max-width: 66.666667%;
  }
}

/* === CYBER AWARENESS PAGE === */
/* CYBER AWARENESS PAGE - FAKE ADS */
/* Custom styling for intentionally deceptive advertisement examples */
.fake-ad {
  background: linear-gradient(135deg, #ff0000 0%, #ff6600 100%);
  border: 3px solid #ffff00;
  border-radius: 8px;
  padding: 0.75rem;
  text-align: center;
  box-shadow: 0 0 20px rgba(255, 0, 0, 0.5);
  animation: fakePulse 2s infinite;
}

body[data-page="awareness"] .fake-ad {
  padding: 1rem;
  font-size: 1.1rem;
}

@keyframes fakePulse {
  0%, 100% { box-shadow: 0 0 20px rgba(255, 0, 0, 0.5); }
  50% { box-shadow: 0 0 30px rgba(255, 0, 0, 0.8); }
}

.fake-ad-header {
  background: #ffff00;
  color: #ff0000;
  font-weight: bold;
  font-size: 0.75rem;
  padding: 0.25rem;
  margin: -1rem -1rem 0.5rem -1rem;
  border-radius: 5px 5px 0 0;
  letter-spacing: 1px;
}

.fake-ad-title {
  color: #ffffff;
  font-size: 1.1rem;
  font-weight: bold;
  margin-bottom: 0.5rem;
  text-shadow: 3px 3px 6px rgba(0, 0, 0, 0.8), 0 0 10px rgba(255, 255, 255, 0.3);
  text-transform: uppercase;
}

body[data-page="awareness"] .fake-ad-title {
  font-size: 1.4rem;
  margin-bottom: 0.75rem;
  line-height: 1.2;
  font-weight: bold;
  color: #ffffff;
  text-shadow: 3px 3px 6px rgba(0, 0, 0, 0.9), 0 0 15px rgba(255, 255, 255, 0.5), 0 0 25px rgba(255, 255, 0, 0.3);
}

.fake-ad-text {
  color: #ffff00;
  font-weight: bold;
  font-size: 1rem;
  margin: 0.5rem 0;
}

body[data-page="awareness"] .fake-ad-text {
  font-size: 1.2rem;
}

.fake-ad-price {
  color: #ffffff;
  font-size: 1.25rem;
  font-weight: bold;
  margin: 0.75rem 0;
}

body[data-page="awareness"] .fake-ad-price {
  font-size: 1.4rem;
}

.fake-ad-price del {
  color: #ffcccc;
  font-size: 0.9rem;
}

.fake-ad-urgency {
  color: #ffff00;
  font-weight: bold;
  font-size: 0.9rem;
  animation: blink 1.5s infinite;
}

body[data-page="awareness"] .fake-ad-urgency {
  font-size: 1.1rem;
}

@keyframes blink {
  0%, 50%, 100% { opacity: 1; }
  25%, 75% { opacity: 0.5; }
}

.fake-ad-button {
  background: #ffff00;
  color: #ff0000;
  border: 3px solid #ffffff;
  padding: 0.75rem 1.5rem;
  font-weight: bold;
  font-size: 1rem;
  border-radius: 25px;
  cursor: not-allowed;
  width: 100%;
  margin: 1rem 0 0.5rem 0;
  text-transform: uppercase;
  letter-spacing: 1px;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
}

body[data-page="awareness"] .fake-ad-button {
  padding: 0.8rem 1.2rem;
  font-size: 1.1rem;
  margin: 1rem 0 0.75rem 0;
  border: 3px solid #ffffff;
  font-weight: bold;
}

.fake-ad-button:hover {
  background: #ffffff;
  transform: scale(1.05);
}

.fake-ad-fine-print {
  color: #ffcccc;
  font-size: 0.65rem;
  margin-top: 0.5rem;
  font-style: italic;
}

.awareness-content {
  background: var(--card-bg);
  padding: 2rem;
}

.awareness-content ul {
  margin-left: 1.5rem;
  margin-bottom: 1rem;
}

.awareness-content li {
  margin-bottom: 0.75rem;
}

/* Awareness page with ads in margins */
body[data-page="awareness"] .page-shell {
  position: relative;
  max-width: 100%;
  padding-left: 2rem;
  padding-right: 2rem;
}

body[data-page="awareness"] .awareness-header {
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}

body[data-page="awareness"] .awareness-layout {
  position: relative;
  max-width: 900px;
  margin: 0 auto;
}

body[data-page="awareness"] .awareness-layout article {
  width: 100%;
}

body[data-page="awareness"] .awareness-layout aside {
  position: fixed;
  width: 480px;
  top: 100px;
  height: 1000px;
  z-index: 10;
}

body[data-page="awareness"] .awareness-ads-left {
  left: 20px;
}

body[data-page="awareness"] .awareness-ads-right {
  right: 20px;
}

body[data-page="awareness"] .fake-ad {
  position: absolute;
  width: 220px;
  font-size: 0.8rem;
  height: 480px;
  overflow: visible;
}

/* Left sidebar - 2x2 grid */
body[data-page="awareness"] .awareness-ads-left .fake-ad:nth-child(1) { top: 0px; left: 0px; }
body[data-page="awareness"] .awareness-ads-left .fake-ad:nth-child(2) { top: 0px; left: 240px; }
body[data-page="awareness"] .awareness-ads-left .fake-ad:nth-child(3) { top: 500px; left: 0px; }
body[data-page="awareness"] .awareness-ads-left .fake-ad:nth-child(4) { top: 500px; left: 240px; }

/* Right sidebar - 2x2 grid */
body[data-page="awareness"] .awareness-ads-right .fake-ad:nth-child(1) { top: 0px; left: 0px; }
body[data-page="awareness"] .awareness-ads-right .fake-ad:nth-child(2) { top: 0px; left: 240px; }
body[data-page="awareness"] .awareness-ads-right .fake-ad:nth-child(3) { top: 500px; left: 0px; }
body[data-page="awareness"] .awareness-ads-right .fake-ad:nth-child(4) { top: 500px; left: 240px; }

.awareness-content {
  background: var(--card-bg);
  padding: 2rem;
}

.awareness-content ul {
  margin-left: 1.5rem;
  margin-bottom: 1rem;
}

.awareness-content li {
  margin-bottom: 0.75rem;
}

@media (max-width: 1400px) {
  body[data-page="awareness"] .awareness-layout aside {
    position: relative;
    width: 100%;
    left: auto !important;
    right: auto !important;
    top: auto;
    margin-bottom: 2rem;
  }
}