/* Custom CSS for HHAB Ljud & Ljus AB website */
/* Dark theme with modern styling */

:root {
    --primary-color: #0d6efd;
    --secondary-color: #6c757d;
    --dark-color: #212529;
    --darker-color: #1a1d20;
    --black-color: #000000;
    --light-color: #f8f9fa;
    --border-color: #495057;
}

/* Global Styles */
body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: var(--dark-color);
    color: var(--light-color);
    line-height: 1.6;
}

/* Smooth scrolling */
html {
    scroll-behavior: smooth;
}

/* Navigation */
.navbar-brand {
    font-size: 1.5rem;
    font-weight: 700;
}

.navbar-nav .nav-link {
    font-weight: 500;
    padding: 0.75rem 1rem;
    transition: color 0.3s ease;
}

.navbar-nav .nav-link:hover {
    color: var(--primary-color) !important;
}

/* Hero Section */
.hero-section {
    background: linear-gradient(135deg, var(--dark-color) 0%, var(--darker-color) 100%);
    position: relative;
    overflow: hidden;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 800 400"><defs><linearGradient id="soundWave" x1="0%" y1="0%" x2="100%" y2="0%"><stop offset="0%" style="stop-color:rgba(13,110,253,0.1);stop-opacity:1" /><stop offset="50%" style="stop-color:rgba(255,193,7,0.1);stop-opacity:1" /><stop offset="100%" style="stop-color:rgba(13,110,253,0.1);stop-opacity:1" /></linearGradient></defs><path d="M0,200 Q100,150 200,200 T400,200 T600,200 T800,200" fill="none" stroke="url(%23soundWave)" stroke-width="2" opacity="0.6"/><path d="M0,180 Q150,130 300,180 T600,180 T800,180" fill="none" stroke="rgba(255,193,7,0.3)" stroke-width="1.5"/><path d="M0,220 Q80,170 160,220 T320,220 T480,220 T640,220 T800,220" fill="none" stroke="rgba(13,110,253,0.4)" stroke-width="1"/><circle cx="100" cy="80" r="3" fill="rgba(255,193,7,0.4)" opacity="0.8"><animate attributeName="opacity" values="0.4;0.8;0.4" dur="2s" repeatCount="indefinite"/></circle><circle cx="300" cy="60" r="2" fill="rgba(13,110,253,0.5)" opacity="0.6"><animate attributeName="opacity" values="0.3;0.7;0.3" dur="3s" repeatCount="indefinite"/></circle><circle cx="500" cy="90" r="2.5" fill="rgba(255,193,7,0.3)" opacity="0.7"><animate attributeName="opacity" values="0.5;0.9;0.5" dur="2.5s" repeatCount="indefinite"/></circle><circle cx="700" cy="70" r="2" fill="rgba(13,110,253,0.4)" opacity="0.5"><animate attributeName="opacity" values="0.2;0.6;0.2" dur="3.5s" repeatCount="indefinite"/></circle></svg>');
    opacity: 0.7;
    animation: soundWaveMove 10s ease-in-out infinite;
}

@keyframes soundWaveMove {
    0%, 100% { transform: translateX(0); }
    50% { transform: translateX(-50px); }
}

.hero-section .container {
    position: relative;
    z-index: 1;
}

.hero-visual {
    animation: float 6s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-20px); }
}

/* Text utilities */
.text-light-50 {
    color: rgba(248, 249, 250, 0.8) !important;
}

/* Cards */
.card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border-radius: 10px;
    overflow: hidden;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
}

/* Portfolio Cards */
.portfolio-card {
    cursor: pointer;
}

.portfolio-image {
    height: 200px;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.portfolio-card:hover .portfolio-image {
    transform: scale(1.05);
}

/* Background variations */
.bg-black {
    background-color: var(--black-color) !important;
}

.bg-darker {
    background-color: var(--darker-color) !important;
}

/* Buttons */
.btn {
    border-radius: 8px;
    font-weight: 500;
    padding: 0.75rem 2rem;
    transition: all 0.3s ease;
}

.btn-primary {
    background: linear-gradient(135deg, #0d6efd 0%, #0b5ed7 100%);
    border: none;
    box-shadow: 0 4px 15px rgba(13, 110, 253, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(13, 110, 253, 0.4);
}

.btn-outline-light {
    border-width: 2px;
    font-weight: 500;
}

.btn-outline-light:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(248, 249, 250, 0.2);
}

/* Form Controls */
.form-control {
    border-radius: 8px;
    border-width: 2px;
    padding: 0.75rem 1rem;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.form-control:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.25rem rgba(13, 110, 253, 0.25);
    background-color: var(--darker-color);
    color: var(--light-color);
}

.form-control::placeholder {
    color: rgba(248, 249, 250, 0.5);
}

/* Contact Info */
.contact-info a {
    transition: color 0.3s ease;
}

.contact-info a:hover {
    color: var(--primary-color) !important;
}

/* Badges */
.badge {
    font-weight: 500;
    padding: 0.5rem 0.75rem;
    border-radius: 6px;
}

/* Section spacing */
section {
    padding: 5rem 0;
}

/* Mobile Optimizations */
@media (max-width: 768px) {
    .display-4 {
        font-size: 2.5rem;
    }
    
    .display-5 {
        font-size: 2rem;
    }
    
    .hero-section {
        padding: 2rem 0;
    }
    
    .hero-section .min-vh-100 {
        min-height: auto !important;
        padding: 3rem 0;
    }
    
    .btn-lg {
        padding: 0.75rem 1.5rem;
        font-size: 1rem;
    }
    
    section {
        padding: 3rem 0;
    }
    
    .hero-visual {
        margin-top: 2rem;
    }
    
    .card-body {
        padding: 1.5rem;
    }
}

@media (max-width: 576px) {
    .display-4 {
        font-size: 2rem;
    }
    
    .display-1 {
        font-size: 3rem;
    }
    
    .navbar-brand {
        font-size: 1.25rem;
    }
    
    .btn {
        padding: 0.6rem 1.5rem;
    }
    
    .hero-visual .display-1 {
        font-size: 2.5rem;
    }
}

/* Loading Animation */
.loading {
    opacity: 0;
    animation: fadeIn 0.6s ease forwards;
}

@keyframes fadeIn {
    to {
        opacity: 1;
    }
}

/* Scroll animations */
.animate-on-scroll {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.6s ease;
}

.animate-on-scroll.animated {
    opacity: 1;
    transform: translateY(0);
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--dark-color);
}

::-webkit-scrollbar-thumb {
    background: var(--border-color);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primary-color);
}

/* Focus styles for accessibility */
.btn:focus,
.form-control:focus,
.nav-link:focus {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}

/* Print styles */
@media print {
    .navbar,
    .btn,
    #contactForm {
        display: none !important;
    }
    
    body {
        background: white !important;
        color: black !important;
    }
    
    .card {
        border: 1px solid #ccc !important;
        background: white !important;
    }
}