/*
Theme Name: Company A - Minimal Visual Theme
Theme URI: https://example.com/company-a-theme
Author: Your Name
Author URI: https://example.com
Description: A clean, minimalist WordPress theme designed for visual product showcases. Features a slim logo header, full-width image gallery, editable footer text, and a premium timed popup modal. Fully responsive and lightweight.
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: company-a-theme
Tags: minimal, visual, responsive, product-showcase, clean
*/

/* ============================================
   CSS RESET & BASE STYLES
   ============================================ */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    font-size: 16px;
    -webkit-text-size-adjust: 100%;
    scroll-behavior: smooth;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #fff;
    overflow-x: hidden;
}

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

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

/* ============================================
   HEADER & LOGO
   ============================================ */
.site-header {
    width: 100%;
    padding: 20px 0;
    background-color: #fff;
    text-align: center;
    position: relative;
    z-index: 100;
}

.logo-container {
    display: inline-block;
    max-width: 200px;
    padding: 0 20px;
}

.logo-container img {
    width: auto;
    max-height: 60px;
    margin: 0 auto;
    transition: opacity 0.3s ease;
}

.logo-container img:hover {
    opacity: 0.8;
}

/* ============================================
   MAIN CONTENT - IMAGE GALLERY
   ============================================ */
.site-main {
    width: 100%;
}

.image-gallery {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 0;
}

.gallery-item {
    width: 100%;
    position: relative;
    overflow: hidden;
}

.gallery-item img {
    width: 100%;
    height: auto;
    object-fit: cover;
    display: block;
    transition: transform 0.5s ease;
}

.gallery-item:hover img {
    transform: scale(1.02);
}

/* Loading animation for images */
.gallery-item img {
    opacity: 0;
    animation: fadeIn 0.6s ease forwards;
}

.gallery-item:nth-child(1) img { animation-delay: 0.1s; }
.gallery-item:nth-child(2) img { animation-delay: 0.2s; }
.gallery-item:nth-child(3) img { animation-delay: 0.3s; }
.gallery-item:nth-child(4) img { animation-delay: 0.4s; }
.gallery-item:nth-child(5) img { animation-delay: 0.5s; }
.gallery-item:nth-child(6) img { animation-delay: 0.6s; }

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ============================================
   FOOTER
   ============================================ */
.site-footer {
    width: 100%;
    padding: 40px 20px;
    background-color: #f8f8f8;
    text-align: center;
    border-top: 1px solid #eee;
}

.footer-text {
    font-size: 14px;
    color: #666;
    max-width: 800px;
    margin: 0 auto;
    line-height: 1.8;
}

/* ============================================
   POPUP MODAL
   ============================================ */
.popup-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(5px);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.4s ease, visibility 0.4s ease;
}

.popup-overlay.active {
    opacity: 1;
    visibility: visible;
}

.popup-modal {
    background-color: #fff;
    max-width: 500px;
    width: 90%;
    padding: 50px 40px;
    text-align: center;
    position: relative;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.25);
    transform: scale(0.9) translateY(20px);
    transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.popup-overlay.active .popup-modal {
    transform: scale(1) translateY(0);
}

.popup-close {
    position: absolute;
    top: 15px;
    right: 20px;
    font-size: 28px;
    color: #999;
    cursor: pointer;
    line-height: 1;
    transition: color 0.3s ease;
    background: none;
    border: none;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.popup-close:hover {
    color: #333;
}

.popup-category {
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 3px;
    text-transform: uppercase;
    color: #888;
    margin-bottom: 20px;
}

.popup-title {
    font-size: 24px;
    font-weight: 300;
    color: #222;
    margin-bottom: 25px;
    line-height: 1.4;
}

.popup-phone {
    font-size: 20px;
    font-weight: 600;
    color: #333;
    margin-bottom: 30px;
    display: block;
}

.popup-phone a {
    color: inherit;
    transition: color 0.3s ease;
}

.popup-phone a:hover {
    color: #0066cc;
}

.popup-button {
    display: inline-block;
    padding: 16px 45px;
    background-color: #222;
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    letter-spacing: 1px;
    text-transform: uppercase;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
}

.popup-button:hover {
    background-color: #444;
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
}

/* ============================================
   RESPONSIVE DESIGN
   ============================================ */

/* Tablet */
@media (max-width: 768px) {
    .logo-container {
        max-width: 160px;
    }
    
    .logo-container img {
        max-height: 50px;
    }
    
    .popup-modal {
        padding: 40px 30px;
        width: 92%;
    }
    
    .popup-category {
        font-size: 11px;
        letter-spacing: 2px;
    }
    
    .popup-title {
        font-size: 20px;
    }
    
    .popup-phone {
        font-size: 18px;
    }
    
    .popup-button {
        padding: 14px 35px;
        font-size: 13px;
    }
}

/* Mobile */
@media (max-width: 480px) {
    .site-header {
        padding: 15px 0;
    }
    
    .logo-container {
        max-width: 140px;
    }
    
    .logo-container img {
        max-height: 45px;
    }
    
    .site-footer {
        padding: 30px 15px;
    }
    
    .footer-text {
        font-size: 13px;
    }
    
    .popup-modal {
        padding: 35px 25px;
        width: 95%;
    }
    
    .popup-close {
        top: 10px;
        right: 15px;
        font-size: 24px;
    }
    
    .popup-category {
        font-size: 10px;
        letter-spacing: 2px;
        margin-bottom: 15px;
    }
    
    .popup-title {
        font-size: 18px;
        margin-bottom: 20px;
    }
    
    .popup-phone {
        font-size: 16px;
        margin-bottom: 25px;
    }
    
    .popup-button {
        padding: 14px 30px;
        font-size: 12px;
        width: 100%;
    }
}

/* Large screens */
@media (min-width: 1400px) {
    .logo-container {
        max-width: 240px;
    }
    
    .logo-container img {
        max-height: 70px;
    }
}

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

/* Focus styles for keyboard navigation */
a:focus-visible,
button:focus-visible {
    outline: 2px solid #0066cc;
    outline-offset: 2px;
}

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