/* GEKO Color Scheme Variables */
:root {
    --geko-yellow: #FFD700;
    --geko-dark-yellow: #FFC107;
    --geko-black: #000000;
    --geko-dark-gray: #1a1a1a;
    --geko-light-gray: #f8f9fa;
    --geko-white: #ffffff;
}

/* Hero Section */
.hero-section {
    background: linear-gradient(135deg, var(--geko-black) 0%, var(--geko-dark-gray) 100%);
    color: var(--geko-white);
    position: relative;
    overflow: hidden;
    min-height: 75vh;
    display: flex;
    align-items: center;
}

.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 100 100"><defs><pattern id="grain" width="100" height="100" patternUnits="userSpaceOnUse"><circle cx="50" cy="50" r="1" fill="%23FFD700" opacity="0.1"/></pattern></defs><rect width="100" height="100" fill="url(%23grain)"/></svg>');
    opacity: 0.3;
}

.hero-content {
    position: relative;
    z-index: 2;
}

.hero-title {
    font-size: 4rem;
    font-weight: 900;
    color: var(--geko-yellow);
    margin-bottom: 0.5rem;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.5);
}

.hero-subtitle {
    font-size: 1.5rem;
    color: var(--geko-white);
    margin-bottom: 1.5rem;
    font-weight: 300;
}

.hero-description {
    font-size: 1.1rem;
    line-height: 1.6;
    margin-bottom: 2rem;
    opacity: 0.9;
}

.hero-buttons .btn-primary {
    background-color: var(--geko-yellow);
    border-color: var(--geko-yellow);
    color: var(--geko-black);
    font-weight: 600;
    transition: all 0.3s ease;
}

.hero-buttons .btn-primary:hover {
    background-color: var(--geko-dark-yellow);
    border-color: var(--geko-dark-yellow);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(255, 215, 0, 0.3);
}

.hero-buttons .btn-outline-light {
    transition: all 0.3s ease;
}

.hero-buttons .btn-outline-light:hover {
    background-color: var(--geko-white);
    color: var(--geko-black);
    transform: translateY(-2px);
}

/* Sections */
.services-section {
    background-color: var(--geko-light-gray);
}

.portfolio-section {
    background-color: var(--geko-white);
}

.about-section {
    background-color: var(--geko-light-gray);
}

.contact-section {
    background: linear-gradient(135deg, var(--geko-dark-gray) 0%, var(--geko-black) 100%);
    color: var(--geko-white);
}

/* Section Titles */
.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--geko-black);
    margin-bottom: 1rem;
    position: relative;
}

.contact-section .section-title {
    color: var(--geko-white);
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 3px;
    background-color: var(--geko-yellow);
}

.section-subtitle {
    font-size: 1.1rem;
    color: #6c757d;
    margin-bottom: 0;
}

.contact-section .section-subtitle {
    color: rgba(255, 255, 255, 0.8);
}

/* Service Cards */
.service-card {
    background: var(--geko-white);
    padding: 2rem;
    border-radius: 10px;
    text-align: center;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
    border: 1px solid #e9ecef;
}

.service-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0,0,0,0.15);
}

.service-icon {
    font-size: 3rem;
    color: var(--geko-yellow);
    margin-bottom: 1.5rem;
}

.service-card h4 {
    color: var(--geko-black);
    margin-bottom: 1rem;
    font-weight: 600;
}

.service-card p {
    color: #6c757d;
    line-height: 1.6;
}

/* Portfolio Items */
.portfolio-item {
    position: relative;
    overflow: hidden;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.portfolio-image {
    position: relative;
    overflow: hidden;
    height: 250px; /* Fixed height for consistency */
}

.portfolio-image img {
    transition: transform 0.3s ease;
    width: 100%;
    height: 250px;
    object-fit: cover;
    display: block; /* Ensure proper display */
}

/* Hero Image Styles */
.hero-image {
    position: relative;
}

.hero-image img {
    width: 100%;
    height: auto;
    max-height: 400px;
    object-fit: cover;
    display: block;
}

/* About Image Styles */
.about-image {
    position: relative;
}

.about-image img {
    width: 100%;
    height: auto;
    max-height: 300px;
    object-fit: cover;
    display: block;
}

/* Image Placeholder Fallback */
.image-placeholder {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 1rem;
    font-size: 1rem;
    font-weight: 600;
    border-radius: 8px;
}

/* Loading state for images */
.hero-image .image-placeholder,
.about-image .image-placeholder {
    min-height: 300px;
    background: linear-gradient(135deg, var(--geko-yellow) 0%, var(--geko-dark-yellow) 100%);
    color: var(--geko-black);
}

.portfolio-image .image-placeholder {
    height: 250px;
    background: linear-gradient(135deg, var(--geko-black) 0%, var(--geko-dark-gray) 100%);
    color: var(--geko-yellow);
}

/* About Section */
.about-stats {
    margin-top: 2rem;
}

.stat-item {
    text-align: center;
}

.stat-item h3 {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--geko-yellow);
    margin-bottom: 0.5rem;
}

.stat-item p {
    color: #6c757d;
    font-weight: 500;
}

/* Contact Section */
.contact-info {
    padding: 2rem;
}

.contact-item {
    display: flex;
    align-items: center;
    margin-bottom: 2rem;
}

.contact-icon {
    font-size: 2rem;
    color: var(--geko-yellow);
    margin-right: 1.5rem;
    width: 60px;
    text-align: center;
}

.contact-content h5 {
    color: var(--geko-white);
    margin-bottom: 0.5rem;
    font-weight: 600;
}

.contact-content p {
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 0;
}

.contact-form {
    background: rgba(255, 255, 255, 0.1);
    padding: 2rem;
    border-radius: 10px;
    backdrop-filter: blur(10px);
}

.contact-form .form-control {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: var(--geko-white);
    padding: 0.75rem 1rem;
}

.contact-form .form-control::placeholder {
    color: rgba(255, 255, 255, 0.6);
}

.contact-form .form-control:focus {
    background: rgba(255, 255, 255, 0.15);
    border-color: var(--geko-yellow);
    color: var(--geko-white);
    box-shadow: 0 0 0 0.25rem rgba(255, 215, 0, 0.25);
}

/* ==============================
   ENHANCED MOBILE OPTIMIZATION 
   ============================== */

/* Mobile-first responsive design for homepage */
@media (max-width: 575.98px) {
    /* Hero section mobile optimization */
    .hero-section {
        min-height: 80vh;
        padding: 2rem 0;
    }
    
    .hero-title {
        font-size: 2.5rem;
        line-height: 1.2;
        margin-bottom: 0.75rem;
    }
    
    .hero-subtitle {
        font-size: 1.1rem;
        margin-bottom: 1rem;
    }
    
    .hero-description {
        font-size: 0.95rem;
        margin-bottom: 1.5rem;
        line-height: 1.5;
    }
    
    .hero-buttons {
        display: flex;
        flex-direction: column;
        gap: 0.75rem;
        width: 100%;
    }
    
    .hero-buttons .btn {
        width: 100%;
        padding: 0.75rem 1rem;
        font-size: 0.95rem;
    }
    
    /* Section titles mobile */
    .section-title {
        font-size: 1.75rem;
        text-align: center;
        margin-bottom: 0.75rem;
    }
    
    .section-subtitle {
        text-align: center;
        font-size: 0.95rem;
        margin-bottom: 2rem;
    }
    
    /* Service cards mobile */
    .service-card {
        padding: 1.5rem;
        margin-bottom: 1rem;
    }
    
    .service-card:hover {
        transform: none; /* Disable hover transform on mobile */
    }
    
    .service-icon {
        font-size: 2.5rem;
        margin-bottom: 1rem;
    }
    
    .service-card h4 {
        font-size: 1.1rem;
        margin-bottom: 0.75rem;
    }
    
    .service-card p {
        font-size: 0.9rem;
        line-height: 1.5;
    }
    
    /* Portfolio mobile */
    .portfolio-image {
        height: 200px;
    }
    
    .portfolio-image img,
    .portfolio-image > div {
        height: 200px;
    }
    
    .portfolio-overlay {
        padding: 1rem;
        opacity: 1; /* Always visible on mobile */
        background: linear-gradient(0deg, rgba(0,0,0,0.8) 0%, transparent 100%);
    }
    
    .portfolio-overlay h5 {
        font-size: 1rem;
        margin-bottom: 0.25rem;
    }
    
    .portfolio-overlay p {
        font-size: 0.85rem;
        margin-bottom: 0;
    }
    
    /* About section mobile */
    .about-stats {
        margin-top: 1.5rem;
    }
    
    .stat-item h3 {
        font-size: 2rem;
        margin-bottom: 0.25rem;
    }
    
    .stat-item p {
        font-size: 0.9rem;
    }
    
    /* Contact section mobile */
    .contact-info {
        padding: 1rem;
        margin-bottom: 1.5rem;
    }
    
    .contact-item {
        margin-bottom: 1.5rem;
        text-align: center;
        flex-direction: column;
    }
    
    .contact-icon {
        margin-right: 0;
        margin-bottom: 0.5rem;
        width: auto;
    }
    
    .contact-content h5 {
        font-size: 1rem;
        margin-bottom: 0.25rem;
    }
    
    .contact-content p {
        font-size: 0.9rem;
    }
    
    .contact-form {
        padding: 1.5rem;
        margin-top: 1rem;
    }
    
    .contact-form .form-control {
        margin-bottom: 1rem;
        font-size: 16px; /* Prevents zoom on iOS */
    }
    
    .contact-form .btn {
        width: 100%;
        padding: 0.75rem 1rem;
    }
}

/* Tablet optimization */
@media (min-width: 576px) and (max-width: 767.98px) {
    .hero-title {
        font-size: 3rem;
    }
    
    .hero-subtitle {
        font-size: 1.3rem;
    }
    
    .section-title {
        font-size: 2rem;
    }
    
    .hero-buttons {
        display: flex;
        flex-direction: column;
        gap: 1rem;
        max-width: 400px;
        margin: 0 auto;
    }
    
    .hero-buttons .btn {
        width: 100%;
    }
    
    .service-card {
        padding: 1.75rem;
    }
    
    .portfolio-image img,
    .portfolio-image > div {
        height: 225px;
    }
}

/* Large mobile/small tablet */
@media (min-width: 768px) and (max-width: 991.98px) {
    .hero-title {
        font-size: 3.5rem;
    }
    
    .hero-subtitle {
        font-size: 1.4rem;
    }
    
    .section-title {
        font-size: 2.2rem;
    }
    
    .hero-buttons {
        display: flex;
        gap: 1rem;
        justify-content: center;
        flex-wrap: wrap;
    }
    
    .hero-buttons .btn {
        flex: 1;
        min-width: 200px;
    }
}

/* Mobile navigation improvements */
@media (max-width: 991.98px) {
    .hero-section .min-vh-100 {
        min-height: 90vh;
    }
}

/* Touch device optimizations */
@media (hover: none) and (pointer: coarse) {
    .service-card:hover {
        transform: none;
        box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    }
    
    .portfolio-item:hover .portfolio-overlay {
        opacity: 1;
    }
    
    .portfolio-item:hover img {
        transform: none;
    }
    
    .hero-buttons .btn-primary:hover {
        transform: none;
        box-shadow: none;
    }
    
    .hero-buttons .btn-outline-light:hover {
        transform: none;
    }
}

/* Smooth Scrolling */
html {
    scroll-behavior: smooth;
}

/* Animation Classes */
.fade-in {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.6s ease;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Reduced motion accessibility */
@media (prefers-reduced-motion: reduce) {
    .fade-in {
        transition: none;
    }
    
    .hero-buttons .btn-primary,
    .hero-buttons .btn-outline-light,
    .service-card,
    .portfolio-item img {
        transition: none;
    }
    
    html {
        scroll-behavior: auto;
    }
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    .hero-title {
        text-shadow: 2px 2px 4px rgba(0,0,0,1);
    }
    
    .section-title::after {
        height: 4px;
    }
    
    .service-card {
        border: 2px solid var(--geko-yellow);
    }
    
    .portfolio-overlay {
        background: linear-gradient(45deg, rgba(0,0,0,0.9) 0%, rgba(0,0,0,0.7) 100%);
    }
}

/* Loading state for images */
.hero-image > div,
.portfolio-image > div,
.about-image > div {
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--geko-yellow) 0%, var(--geko-dark-yellow) 100%);
    color: var(--geko-black);
    font-weight: bold;
    border-radius: 8px;
    min-height: 200px;
}

@media (max-width: 575.98px) {
    .hero-image > div,
    .about-image > div {
        min-height: 250px;
        font-size: 0.9rem;
        text-align: center;
        padding: 1rem;
    }
    
    .portfolio-image > div {
        min-height: 200px;
        font-size: 0.85rem;
    }
}