/* =============================================
   MultimediaTech - Main Stylesheet
   ============================================= */

:root {
    --primary: #0f4c81;
    --primary-dark: #0a3560;
    --primary-light: #1a6bb5;
    --accent: #00b4d8;
    --accent-dark: #0096b7;
    --dark: #1a1a2e;
    --dark-light: #2d2d44;
    --gray-900: #212529;
    --gray-700: #495057;
    --gray-500: #6c757d;
    --gray-300: #dee2e6;
    --gray-100: #f8f9fa;
    --white: #ffffff;
    --success: #28a745;
    --danger: #dc3545;
    --shadow: 0 2px 15px rgba(0,0,0,0.08);
    --shadow-lg: 0 10px 40px rgba(0,0,0,0.12);
    --radius: 12px;
    --radius-sm: 8px;
    --transition: all 0.3s ease;
}

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

html { scroll-behavior: smooth; }

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    color: var(--gray-700);
    line-height: 1.6;
    background: var(--white);
    -webkit-font-smoothing: antialiased;
}

a { color: var(--primary); text-decoration: none; transition: var(--transition); }
a:hover { color: var(--accent); }

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

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* =============================================
   Buttons
   ============================================= */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 28px;
    border: 2px solid transparent;
    border-radius: 50px;
    font-family: inherit;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
}

.btn-primary {
    background: var(--primary);
    color: var(--white);
    border-color: var(--primary);
}
.btn-primary:hover {
    background: var(--primary-dark);
    border-color: var(--primary-dark);
    color: var(--white);
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(15,76,129,0.3);
}

.btn-outline {
    background: transparent;
    color: var(--white);
    border-color: var(--white);
}
.btn-outline:hover {
    background: var(--white);
    color: var(--primary);
    transform: translateY(-2px);
}

.btn-lg { padding: 16px 40px; font-size: 1.1rem; }

/* =============================================
   Navbar
   ============================================= */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    padding: 12px 0;
    transition: var(--transition);
    background: var(--dark);
    box-shadow: 0 2px 10px rgba(0,0,0,0.2);
}

.navbar.scrolled {
    background: var(--dark);
    box-shadow: 0 2px 15px rgba(0,0,0,0.3);
    padding: 10px 0;
}

.navbar .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.4rem;
    color: var(--white);
    text-decoration: none;
}

.navbar.scrolled .logo { color: var(--white); }

.logo-icon {
    font-size: 1.6rem;
    color: var(--accent);
}

.logo-text { font-weight: 300; }
.logo-text strong { font-weight: 700; }

.nav-menu {
    display: flex;
    list-style: none;
    gap: 5px;
}

.nav-menu a {
    display: block;
    padding: 8px 18px;
    color: rgba(255,255,255,0.9);
    font-weight: 500;
    font-size: 0.9rem;
    border-radius: 50px;
    transition: var(--transition);
}

.navbar.scrolled .nav-menu a { color: rgba(255,255,255,0.9); }

.nav-menu a:hover,
.nav-menu a.active {
    color: var(--white);
    background: rgba(255,255,255,0.12);
}

.navbar.scrolled .nav-menu a:hover,
.navbar.scrolled .nav-menu a.active {
    color: var(--white);
    background: rgba(255,255,255,0.12);
}

.nav-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 5px;
}

.nav-toggle span {
    display: block;
    width: 25px;
    height: 2px;
    background: var(--white);
    transition: var(--transition);
}

.navbar.scrolled .nav-toggle span { background: var(--white); }

/* =============================================
   Hero Section
   ============================================= */
.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    background: linear-gradient(135deg, var(--dark) 0%, var(--primary-dark) 50%, var(--primary) 100%);
    background-size: cover;
    background-position: center;
    overflow: hidden;
}

.hero[style*="background-image"] {
    background-blend-mode: overlay;
    background-color: rgba(26,26,46,0.45);
}

.hero::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 70%;
    height: 200%;
    background: radial-gradient(ellipse, rgba(0,180,216,0.15) 0%, transparent 70%);
    animation: pulse 8s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 0.5; transform: scale(1); }
    50% { opacity: 1; transform: scale(1.1); }
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="g" patternUnits="userSpaceOnUse" width="20" height="20"><circle cx="10" cy="10" r="0.5" fill="rgba(255,255,255,0.05)"/></pattern></defs><rect fill="url(%23g)" width="100" height="100"/></svg>');
}

.hero-content {
    position: relative;
    z-index: 2;
    padding: 120px 0 80px;
}

.hero h1 {
    font-size: clamp(2.2rem, 5vw, 3.8rem);
    font-weight: 800;
    color: var(--white);
    line-height: 1.15;
    margin-bottom: 24px;
}

.hero h1 span { color: var(--accent); }

.hero-subtitle {
    font-size: clamp(1rem, 2vw, 1.2rem);
    color: rgba(255,255,255,0.8);
    max-width: 600px;
    margin-bottom: 40px;
    line-height: 1.7;
}

.hero-buttons { display: flex; gap: 15px; flex-wrap: wrap; }

/* =============================================
   Section Styles
   ============================================= */
.section-header {
    text-align: center;
    margin-bottom: 60px;
}

.section-header h2 {
    font-size: clamp(1.8rem, 3vw, 2.4rem);
    font-weight: 700;
    color: var(--dark);
    margin-bottom: 12px;
}

.section-header p {
    font-size: 1.1rem;
    color: var(--gray-500);
}

/* =============================================
   Services Section
   ============================================= */
.services {
    padding: 100px 0;
    background: var(--gray-100);
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 30px;
}

.service-card {
    background: var(--white);
    border-radius: var(--radius);
    padding: 40px 30px;
    box-shadow: var(--shadow);
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--primary), var(--accent));
    transform: scaleX(0);
    transition: var(--transition);
}

.service-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
}

.service-card:hover::before { transform: scaleX(1); }

.service-icon {
    width: 70px;
    height: 70px;
    border-radius: 16px;
    background: linear-gradient(135deg, var(--primary), var(--accent));
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.6rem;
    color: var(--white);
    margin-bottom: 24px;
}

.service-card h3 {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--dark);
    margin-bottom: 12px;
}

.service-card p {
    color: var(--gray-500);
    line-height: 1.7;
    margin-bottom: 20px;
}

.service-link {
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--primary);
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.service-link:hover { gap: 12px; color: var(--accent); }

/* =============================================
   Why Us Section
   ============================================= */
.why-us {
    padding: 100px 0;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 40px;
}

.feature {
    text-align: center;
    padding: 20px;
}

.feature-icon {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: var(--gray-100);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    color: var(--primary);
    margin: 0 auto 20px;
    transition: var(--transition);
}

.feature:hover .feature-icon {
    background: var(--primary);
    color: var(--white);
    transform: scale(1.1);
}

.feature h4 {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--dark);
    margin-bottom: 10px;
}

.feature p { color: var(--gray-500); }

/* =============================================
   CTA Section
   ============================================= */
.cta {
    padding: 80px 0;
    background: linear-gradient(135deg, var(--dark) 0%, var(--primary-dark) 100%);
    text-align: center;
}

.cta h2 {
    font-size: clamp(1.5rem, 3vw, 2rem);
    color: var(--white);
    margin-bottom: 16px;
}

.cta p {
    color: rgba(255,255,255,0.7);
    font-size: 1.1rem;
    margin-bottom: 30px;
}

/* =============================================
   Page Header
   ============================================= */
.page-header {
    padding: 160px 0 80px;
    background: linear-gradient(135deg, var(--dark) 0%, var(--primary-dark) 100%);
    background-size: cover;
    background-position: center;
    text-align: center;
}

.page-header h1 {
    font-size: clamp(1.8rem, 4vw, 2.8rem);
    font-weight: 700;
    color: var(--white);
    margin-bottom: 10px;
}

.page-header p {
    color: rgba(255,255,255,0.7);
    font-size: 1.1rem;
}

/* =============================================
   Page Content
   ============================================= */
.page-content {
    padding: 80px 0;
}

.content-body {
    max-width: 800px;
    margin: 0 auto;
    font-size: 1.05rem;
    line-height: 1.8;
}

.content-body h2 { font-size: 1.8rem; color: var(--dark); margin: 40px 0 16px; }
.content-body h3 { font-size: 1.4rem; color: var(--dark); margin: 30px 0 12px; }
.content-body p { margin-bottom: 16px; }
.content-body ul, .content-body ol { margin: 16px 0; padding-left: 30px; }
.content-body li { margin-bottom: 8px; }
.content-body img { border-radius: var(--radius-sm); margin: 20px 0; }

/* =============================================
   Contact Section
   ============================================= */
.contact-section { padding: 80px 0; }

.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 60px;
    align-items: start;
}

.contact-info { display: flex; flex-direction: column; gap: 20px; }

.contact-card {
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 20px;
    background: var(--gray-100);
    border-radius: var(--radius-sm);
    transition: var(--transition);
}

.contact-card:hover {
    background: var(--primary);
    color: var(--white);
    transform: translateX(5px);
}

.contact-card:hover a,
.contact-card:hover h3,
.contact-card:hover p { color: var(--white); }

.contact-icon {
    width: 50px;
    height: 50px;
    border-radius: 12px;
    background: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
    font-size: 1.1rem;
    flex-shrink: 0;
}

.contact-card:hover .contact-icon { background: rgba(255,255,255,0.2); }

.contact-card h3 {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--gray-500);
    margin-bottom: 4px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.contact-card p, .contact-card a {
    font-size: 1rem;
    color: var(--dark);
    font-weight: 500;
}

.contact-form-wrap h2 {
    font-size: 1.6rem;
    font-weight: 700;
    color: var(--dark);
    margin-bottom: 24px;
}

.contact-form .form-group {
    margin-bottom: 20px;
}

.contact-form label {
    display: block;
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--gray-700);
    margin-bottom: 6px;
}

.contact-form input,
.contact-form textarea {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid var(--gray-300);
    border-radius: var(--radius-sm);
    font-family: inherit;
    font-size: 1rem;
    transition: var(--transition);
    background: var(--white);
}

.contact-form input:focus,
.contact-form textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(15,76,129,0.1);
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

/* =============================================
   Alerts
   ============================================= */
.alert {
    padding: 14px 20px;
    border-radius: var(--radius-sm);
    margin-bottom: 20px;
    font-weight: 500;
}

.alert-success { background: #d4edda; color: #155724; border: 1px solid #c3e6cb; }
.alert-error { background: #f8d7da; color: #721c24; border: 1px solid #f5c6cb; }

/* =============================================
   Realizacje / Gallery
   ============================================= */
.realizacje-section { padding: 80px 0; }

.realizacje-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 30px;
}

.realizacja-card {
    background: var(--white);
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.realizacja-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.realizacja-cover {
    position: relative;
    aspect-ratio: 4/3;
    overflow: hidden;
    background: var(--gray-100);
}

.realizacja-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.realizacja-card:hover .realizacja-cover img {
    transform: scale(1.05);
}

.realizacja-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3rem;
    color: var(--gray-300);
}

.photo-count {
    position: absolute;
    top: 12px;
    right: 12px;
    background: rgba(0,0,0,0.7);
    color: var(--white);
    padding: 4px 12px;
    border-radius: 50px;
    font-size: 0.8rem;
    font-weight: 600;
    backdrop-filter: blur(4px);
}

.realizacja-overlay {
    position: absolute;
    inset: 0;
    background: rgba(15,76,129,0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: var(--transition);
}

.realizacja-card:hover .realizacja-overlay { opacity: 1; }

.realizacja-overlay .btn-sm {
    padding: 10px 24px;
    font-size: 0.85rem;
    border-color: var(--white);
    color: var(--white);
    border-radius: 50px;
    background: transparent;
    cursor: pointer;
    font-weight: 600;
    transition: var(--transition);
}

.realizacja-overlay .btn-sm:hover {
    background: var(--white);
    color: var(--primary);
}

.realizacja-info {
    padding: 20px 24px;
}

.realizacja-info h3 {
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--dark);
    margin-bottom: 6px;
}

.realizacja-info p {
    color: var(--gray-500);
    font-size: 0.9rem;
    line-height: 1.6;
}

/* =============================================
   Lightbox
   ============================================= */
.lightbox {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.95);
    z-index: 9999;
    display: none;
    align-items: center;
    justify-content: center;
}

.lightbox.active { display: flex; }

.lightbox-content {
    position: relative;
    max-width: 90vw;
    max-height: 90vh;
    text-align: center;
}

.lightbox-content img {
    max-width: 90vw;
    max-height: 80vh;
    object-fit: contain;
    border-radius: 4px;
}

.lightbox-close,
.lightbox-prev,
.lightbox-next {
    position: fixed;
    background: none;
    border: none;
    color: rgba(255,255,255,0.7);
    font-size: 1.5rem;
    cursor: pointer;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
    z-index: 10;
}

.lightbox-close:hover,
.lightbox-prev:hover,
.lightbox-next:hover { color: var(--white); }

.lightbox-close { top: 20px; right: 20px; font-size: 2rem; }
.lightbox-prev { left: 20px; top: 50%; transform: translateY(-50%); }
.lightbox-next { right: 20px; top: 50%; transform: translateY(-50%); }

.lightbox-caption {
    color: var(--white);
    font-size: 1.1rem;
    font-weight: 600;
    margin-top: 16px;
}

.lightbox-counter {
    color: rgba(255,255,255,0.5);
    font-size: 0.85rem;
    margin-top: 6px;
}

/* =============================================
   Error Page
   ============================================= */
.error-page {
    min-height: 70vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 120px 0 80px;
    text-align: center;
}

.error-content h1 {
    font-size: 8rem;
    font-weight: 800;
    color: var(--gray-300);
    line-height: 1;
}

.error-content h2 {
    font-size: 1.6rem;
    color: var(--dark);
    margin-bottom: 12px;
}

.error-content p {
    color: var(--gray-500);
    margin-bottom: 30px;
}

/* =============================================
   Footer
   ============================================= */
.footer {
    background: var(--dark);
    padding: 60px 0 0;
    color: rgba(255,255,255,0.7);
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr;
    gap: 40px;
    padding-bottom: 40px;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

.footer-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.3rem;
    color: var(--white);
    margin-bottom: 16px;
}

.footer-logo .logo-icon { color: var(--accent); font-size: 1.5rem; }
.footer-logo .logo-text { font-weight: 300; }
.footer-logo .logo-text strong { font-weight: 700; }

.footer-col h4 {
    color: var(--white);
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 20px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.footer-col ul { list-style: none; }

.footer-col ul li { margin-bottom: 10px; }

.footer-col ul a {
    color: rgba(255,255,255,0.6);
    transition: var(--transition);
}

.footer-col ul a:hover { color: var(--accent); }

.footer-contact li {
    display: flex;
    align-items: center;
    gap: 10px;
}

.footer-contact i { color: var(--accent); width: 16px; }

.footer-bottom {
    padding: 20px 0;
    text-align: center;
    font-size: 0.85rem;
    color: rgba(255,255,255,0.4);
}

/* =============================================
   Responsive Design
   ============================================= */
@media (max-width: 992px) {
    .footer-grid { grid-template-columns: 1fr 1fr; }
    .contact-grid { grid-template-columns: 1fr; }
}

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

    .nav-menu {
        position: fixed;
        top: 0;
        right: -100%;
        width: 280px;
        height: 100vh;
        background: var(--dark);
        flex-direction: column;
        padding: 80px 30px 30px;
        gap: 0;
        transition: var(--transition);
        box-shadow: -5px 0 30px rgba(0,0,0,0.3);
    }

    .nav-menu.open { right: 0; }

    .nav-menu a {
        color: rgba(255,255,255,0.8) !important;
        padding: 12px 16px;
        border-radius: var(--radius-sm);
        font-size: 1rem;
    }

    .nav-menu a:hover,
    .nav-menu a.active {
        background: rgba(255,255,255,0.1) !important;
        color: var(--white) !important;
    }

    .hero { min-height: 80vh; }

    .hero h1 { font-size: 2rem; }

    .services-grid { grid-template-columns: 1fr; }

    .realizacje-grid { grid-template-columns: 1fr; }

    .features-grid { grid-template-columns: 1fr 1fr; gap: 20px; }

    .form-row { grid-template-columns: 1fr; }

    .footer-grid { grid-template-columns: 1fr; }

    .hero-buttons { flex-direction: column; }
    .hero-buttons .btn { text-align: center; justify-content: center; }
}

@media (max-width: 480px) {
    .features-grid { grid-template-columns: 1fr; }

    .error-content h1 { font-size: 5rem; }

    .container { padding: 0 15px; }
}
