/* Responsive enhancements for Seena's portfolio - Works alongside existing styles */

/* Mobile-first responsive improvements */
@media (max-width: 768px) {
  /* Improve readability on mobile */
  body {
    font-size: 16px;
    line-height: 1.5;
  }
  
  /* Better spacing for mobile */
  .container, .page-content {
    padding-left: 15px;
    padding-right: 15px;
  }
  
  /* Adjust typography for mobile */
  h1 {
    font-size: 2.5rem !important;
    line-height: 1.2;
  }
  
  h2 {
    font-size: 1.8rem !important;
  }
  
  /* Improve project titles on mobile */
  .project-title {
    font-size: 1.5rem !important;
    margin-bottom: 0.5rem;
  }
  
  .project-tag, .project-year {
    font-size: 1rem !important;
  }
  
  /* Better image handling on mobile */
  .img-fluid {
    max-width: 100%;
    height: auto;
  }
  
  /* Improve gallery layouts on mobile */
  gallery-grid {
    grid-template-columns: 1fr !important;
    gap: 1rem !important;
  }
  
  /* Better column layouts on mobile */
  column-set {
    display: block !important;
  }
  
  column-unit {
    display: block !important;
    width: 100% !important;
    margin-bottom: 1.5rem;
  }
  
  /* Improve navigation on mobile */
  .navbar {
    padding: 0.5rem 0;
  }
  
  .logo {
    max-width: 120px;
  }
  
  /* Better button sizing on mobile */
  .btn {
    padding: 0.75rem 1.5rem;
    width: 100%;
    margin-bottom: 0.5rem;
  }
}

/* Tablet improvements */
@media (min-width: 769px) and (max-width: 1024px) {
  h1 {
    font-size: 3.5rem !important;
  }
  
  h2 {
    font-size: 2rem !important;
  }
  
  .project-title {
    font-size: 2rem !important;
  }
  
  gallery-grid {
    grid-template-columns: repeat(2, 1fr) !important;
  }
}

/* Modern hover effects that work with your yellow theme */
/* Background hover removed - only text color changes now */
a:hover {
  background-color: transparent !important;
}

/* Smooth scrolling for the whole site */
html {
  scroll-behavior: smooth;
}

/* Improve image loading experience */
.img-loading {
  background: linear-gradient(90deg, #2a2a2a 25%, #333 50%, #2a2a2a 75%);
  background-size: 200% 100%;
  animation: loading 1.5s infinite;
  border-radius: 4px;
}

@keyframes loading {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

/* Better focus states for accessibility (keyboard only, not mouse/touch clicks) */
:focus-visible {
  outline: 2px solid #FFF800;
  outline-offset: 2px;
}

:focus:not(:focus-visible) {
  outline: none;
}

/* Improve selection color to match your theme */
::selection {
  background-color: #FFF800;
  color: #000;
}

::-moz-selection {
  background-color: #FFF800;
  color: #000;
}

/* Print styles */
@media print {
  .navbar, .btn, gallery-slideshow::part(slideshow-nav) {
    display: none !important;
  }
  
  body {
    background: white !important;
    color: black !important;
    font-size: 12pt;
  }
  
  a {
    color: black !important;
    text-decoration: underline;
  }
  
  img {
    max-width: 100% !important;
    page-break-inside: avoid;
  }
}

/* Dark mode support (respects user preference) */
@media (prefers-color-scheme: dark) {
  /* Your site is already dark, so this just ensures compatibility */
  body {
    background-color: #171717;
    color: #ffffff;
  }
}

/* Reduced motion preferences */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* High contrast mode support */
@media (prefers-contrast: high) {
  a:hover {
    background-color: transparent !important;
    color: #FFFF00 !important;
    text-decoration: underline;
  }
  
  :focus-visible {
    outline: 3px solid #FFFF00;
  }
}

/* Custom scrollbar that matches your theme 
::-webkit-scrollbar {
  width: 10px;
}

::-webkit-scrollbar-track {
  background: #1a1a1a;
}

::-webkit-scrollbar-thumb {
  background: #FFF800;
  border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
  background: #FFE600;
}*/

/* Improve form elements if you have any */
input, textarea, select {
  font-family: inherit;
  font-size: inherit;
  padding: 0.5rem;
  border: 1px solid #444;
  background: #222;
  color: #fff;
  border-radius: 4px;
}

input:focus, textarea:focus, select:focus {
  border-color: #FFF800;
  outline: none;
}

/* Utility classes for quick adjustments */
.text-balance {
  text-wrap: balance;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Improve link underlines for readability */
/* Underline removed - only text color changes on hover */
a:not(.image-link) {
  text-decoration: none;
  position: relative;
}

a:not(.image-link):hover::after {
  content: none;
}

/* Better image aspect ratio handling */
.media-item img {
  aspect-ratio: attr(width) / attr(height);
  object-fit: cover;
}

/* Improve spacing between sections */
section, .page-section {
  margin-bottom: 3rem;
}

@media (max-width: 768px) {
  section, .page-section {
    margin-bottom: 2rem;
  }
}