/* --- NEW MODERN COLORS --- */
/* --- NEW DARK MODERN COLORS --- */
:root {
    --primary-color: #00BCD4;  /* A professional Cyan/Turquoise */
    --secondary-color: #00ACC1; /* Slightly darker for hover/accents */
    --accent-color: #FF1744; 
    --dark-bg-color: #1a1a2e;   /* Very dark blue/purple for main background */
    --text-light: #e0e0e0;      /* Light gray for text on dark backgrounds */
    --text-accent: #b3e5fc;     /* Lighter blue for subtle text highlights */
    --box-bg-color: rgba(30, 30, 50, 0.9); /* Slightly lighter box background with opacity */
    --border-color: #3f3f5a;    /* Darker border for contrast */
}

body {
    font-family: 'Segoe UI', Arial, sans-serif; /* Modern font */
    line-height: 1.8; /* Increased line height for readability on dark backgrounds */
    margin: 0;
    padding: 0;
    background-color: var(--dark-bg-color); /* Default very dark background */
    color: var(--text-light); /* Light text by default */
    font-size: 1.05rem; /* Slightly larger base font size */
}
header {
    background: var(--dark-bg-color); /* Keep header dark or make it an accent */
    color: var(--text-light);
    padding: 1rem 0;
    box-shadow: 0 4px 10px rgba(0,0,0,0.3); /* More pronounced shadow */
    border-bottom: 1px solid var(--border-color);
}
header nav a {
    color: var(--text-accent); /* Navigation links color */
    text-decoration: none;
    margin: 0 1.5rem;
    padding-bottom: 5px;
    position: relative;
    transition: color 0.3s ease;
}
header nav a:hover {
    color: var(--primary-color); /* Primary green on hover */
}
header nav a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    display: block;
    margin-top: 5px;
    left: 0;
    background: var(--primary-color); /* Green underline */
    transition: width 0.3s ease;
}
header nav a:hover::after {
    width: 100%;
}
main {
    padding: 2rem;
}
article {
    background: rgba(30, 30, 50, 0.35) !important; /* Transparency set to 35% opaque */
    padding: 2.5rem; /* Increased padding */
    margin-bottom: 1.5rem;
    border-radius: 12px; /* Slightly more rounded corners */
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.4); /* Deeper shadow */
    transition: transform 0.3s ease-in-out, box-shadow 0.3s ease-in-out;
    border: 1px solid var(--border-color); /* Subtle border */
}

article:hover {
    background: rgba(30, 30, 50, 0.7);
    transform: translateY(-10px); /* More pronounced lift on hover */
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.6);
    box-shadow: 0 5px 20px rgba(0, 188, 212, 0.8), /* Turquoise Glow */
                /* 0 0 10px rgba(0, 188, 212, 0.6);   Inner Glow */
}

/* Style links within the main content area */
article a {
    color: var(--primary-color); /* Turquoise links */
    text-decoration: none; /* Remove default underline */
    border-bottom: 1px solid transparent;
    transition: color 0.3s ease, border-color 0.3s ease;
}

article a:hover {
    color: var(--secondary-color); /* Slightly darker turquoise on hover */
    border-bottom: 1px solid var(--primary-color); /* Subtle underline on hover */
}
h1, h2 {
    color: var(--primary-color); /* Headings use the vibrant green */
    margin-bottom: 1rem;
}
p {
    margin-bottom: 1rem;
    color: var(--text-light) !important; /* CRITICAL: Use !important if needed to override inherited body style */
}
strong {
    /* Use the main light text color */
    color: var(--text-light); 
}
ul {
    list-style-type: none;
    padding: 0;
}
ul li {
    background-color: rgba(30, 30, 50, 0.35) !important;
    padding: 12px 20px;
    margin-bottom: 10px;
    border-radius: 8px; /* Slightly more rounded */
    border-left: 5px solid transparent;
    cursor: default;
    transition: all 0.2s ease-in-out;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

ul li:hover {
    border-left: 5px solid var(--accent-color); /* Use accent red on hover */
    box-shadow: 0 4px 15px rgba(255, 23, 68, 0.4); /* Red/Accent shadow */
    transform: translateX(10px) scale(1.02); /* More pronounced slide and slight zoom */
}
/* Logo Styling */
.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 2rem;
}
.logo {
    height: 50px;
    width: auto;
}

/* Animation and Hover Effects for Articles */
article {
    /* Keep existing styles */
    background: #fff;
    padding: 2rem;
    margin-bottom: 1.5rem;
    border-radius: 8px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);

    /* Add transition for smooth animation */
    transition: transform 0.3s ease-in-out, box-shadow 0.3s ease-in-out;
}

article:hover {
    /* Scale up slightly on hover */
    transform: translateY(-5px);
    /* Add a more pronounced shadow */
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
}
/* Style for List Items (Making them look like clickable cards) */
ul li {
    background-color: var(--background-white);
    padding: 10px 15px;
    margin-bottom: 10px;
    border-radius: 5px;
    border-left: 5px solid transparent;
    cursor: default; /* Change cursor to pointer/default for better UX */
    transition: all 0.2s ease-in-out;
}

ul li:hover {
    border-left: 5px solid var(--primary-color); /* Highlight with the primary color */
    box-shadow: 0 1px 5px rgba(0, 0, 0, 0.1);
    transform: translateX(5px); /* Slide slightly to the right */
}

/* Ensure headings have the primary color */
h1, h2 {
    color: var(--primary-color); 
}
/* Keyframe Animation for Subtle Background Shift */
@keyframes subtle-bg-shift {
    0% { background-color: #f8f9fa; } /* Light gray */
    50% { background-color: #f6f7f8; } /* Slightly lighter gray/blue tint */
    100% { background-color: #f8f9fa; }
}
.background-home {
    background-image: url('../img/home.png');
    background-size: 115%;;
    background-position: relative;
    background-attachment: scroll !important;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    position: relative;
    animation: subtle-pan 20s ease-in-out infinite alternate; /* Very slow, smooth cycle */
    overflow: hidden; /* Prevent the image edges from showing during movement */
    /* Prepare for the JavaScript transform */
    transition: transform 0.1s linear; /* Fast transition for smooth tracking */
    will-change: transform; /* Hint to the browser for performance */
    white-space: pre-line;  /* turns \n into real line breaks */
}

.background-home::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6); /* Dark overlay for text readability */
    z-index: 1;
}

.background-about {
    background-image: url('../img/about.png');
    background-size: 110%;
    background-position: center center;
    background-attachment: fixed;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    /* Apply the new animation */
    animation: subtle-pan 20s ease-in-out infinite alternate; /* Very slow, smooth cycle */
    position: relative;
    overflow: hidden;
}

.background-about::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    z-index: 1;
}

.background-portfolio {
    background-image: url('../img/portfolio.png');
    background-size: 110%;
    background-position: center center;
    background-attachment: fixed;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    animation: subtle-pan 20s ease-in-out infinite alternate; 
    position: relative;
    overflow: hidden;
}

.background-portfolio::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    z-index: 1;
}

/* Contact Page Background (Static) */
.background-contact {
    background-image: url('../img/contact.png'); 
    background-size: cover;
    background-position: center center;
    background-attachment: fixed;
    min-height: 100vh;
    padding: 50px 0;
    position: relative;
    overflow: hidden;
}

.background-contact::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6); 
    z-index: 0;
}

/* Ensure content is above the overlay */
.background-home > *, .background-about > *, .background-portfolio > *, .background-contact > * {
    z-index: 2;
    position: relative;
}

.home-content-wrapper {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    height: 100%;
    min-height: 100vh;
}

.hero-text-box {
    /* CRITICAL FIX: Ensures the default, non-hover state is dark and transparent */
    background: rgba(30, 30, 50, 0.35) !important;  
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.5); 
    padding: 40px;
    text-align: center;
    border-radius: 12px;
    max-width: 80%;
    
    /* Subtle animation for the transition */
    transition: all 0.3s ease-in-out;
}

.hero-text-box:hover {
    /* Hover effect is usually slightly less transparent for visual feedback */
    background: rgba(30, 30, 50, 0.6);
    box-shadow: 0 0 30px rgba(0, 188, 212, 0.8); /* Using a transparent primary color (Turquoise) */ 
    transform: scale(1.02) translateY(-5px);
}

/* Keyframe Animation for Subtle Background Movement */
@keyframes subtle-pan {
    0% {
        background-size: 110%; /* Start slightly zoomed in */
        background-position: 50% 50%; /* Center position */
    }
    50% {
        background-size: 115%; /* Zoom in a little more */
        background-position: 55% 55%; /* Pan slightly down and right */
    }
    100% {
        background-size: 110%; /* Return to original zoom */
        background-position: 50% 50%; /* Return to center */
    }
}


/* Responsive styling for the embedded Google Map */
.map-container {
    position: relative;
    width: 100%;
    /* Use padding-bottom to enforce a 4:3 aspect ratio (450/600 = 75%) */
    padding-bottom: 75%; 
    height: 0;
    overflow: hidden;
    margin-top: 2rem; /* Spacing below the text */
    border-radius: 8px; /* Match site aesthetic */
    box-shadow: 0 0 15px rgba(0, 0, 0, 0.7); /* Deep shadow */
}

.map-container iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 0; /* Remove the default iframe border */
}

/* Optional: Ensure the article is wide enough to hold the map */
article {
    max-width: 1000px; /* Increase width for a better map view */
    margin: 20px auto; 
}

/* ================================================= */
/* === MOBILE RESPONSIVENESS (Max Width: 768px) === */
/* ================================================= */
@media screen and (max-width: 768px) {
    
    /* 1. Header and Navigation */
    header .header-container {
        flex-direction: column; /* Stack logo and nav vertically */
        padding: 10px;
    }

    header nav {
        flex-direction: column; /* Stack navigation links vertically */
        align-items: center;
        width: 100%;
        margin-top: 10px;
    }
    
    header nav a {
        padding: 8px 0; /* Increase vertical padding for easier tapping */
        margin: 0;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
        width: 100%; /* Make links full width */
        text-align: center;
    }
    
    .lang-switch-button {
        margin-bottom: 10px;
    }
    
    /* 2. Main Content and Articles */
    
    /* Reduce padding on the main containers */
    .background-home, .background-about, .background-portfolio, .background-contact {
        padding: 30px 0;
        /* Ensure animated background stays large */
        background-size: 150% !important; 
    }

    /* Adjust article padding and remove margins */
    article {
        padding: 1.5rem; 
        margin: 1rem 10px; /* Add horizontal margin and reduce vertical margin */
        max-width: calc(100% - 20px); /* Ensure it fits the screen width */
    }

    /* Adjust typography for mobile readability */
    h1 {
        font-size: 2rem;
    }
    
    h2 {
        font-size: 1.5rem;
    }
    
    p {
        font-size: 1rem;
    }
    
    /* 3. Home Page Hero Text */
    .hero-text-box {
        padding: 25px; /* Reduce padding */
        max-width: 95%; /* Make it wider */
    }
    
    /* 4. Portfolio List Items */
    ul li {
        padding: 10px 15px;
    }

    /* 5. Maps (Ensure aspect ratio is maintained) */
    .map-container {
        /* Change aspect ratio to be taller on mobile (3:4 ratio - 133%) */
        padding-bottom: 133%; 
        margin-left: 0;
        margin-right: 0;
    }
}


/* -------------------------------------- */
/* 2. Call to Action Button Styling */
/* -------------------------------------- */

/* Base button style */
.btn-primary {
    display: inline-block; /* Allows padding and width to be set */
    padding: 12px 24px;   /* Vertical and horizontal spacing inside the button */
    border-radius: 6px;   /* Slightly rounded corners */
    text-decoration: none; /* Remove the standard underline from the link */
    font-weight: 600;     /* Make the text bold */
    font-size: 100%;      /* Set a standard size */
    margin-top: 20px;     /* Give it some space from the text above */

    /* Color Scheme */
    background-color: #007bff; /* A distinct blue for the button background */
    color: #ffffff;          /* White text color */
    border: 1px solid #007bff; /* Matching border color */
    transition: background-color 0.3s, color 0.3s, border-color 0.3s; /* Smooth transitions for hover effect */
}

/* Hover effect for user feedback */
.btn-primary:hover {
    background-color: #0056b3; /* Darker blue on hover */
    border-color: #0056b3;
    color: #ffffff;
}

/* -------------------------------------- */
/* 2. Image as Button Styling (FINAL ATTEMPT) */
/* -------------------------------------- */

/* Style for the link wrapper to allow block-level placement */
.image-cta {
    display: inline-block;
}

/* Style the image itself (Base State) */
.image-cta img {
    width: 150px;
    height: auto;
    border: none;
    display: block;
    transition: all 0.4s ease-in-out; /* Smooth transitions for all properties */

    /* BASE GLOW: Using filter: drop-shadow for guaranteed visibility on an image */
    /* This creates a soft, always-on blue glow */
    filter: drop-shadow(0 0 8px rgba(0, 123, 255, 0.6));
    
    /* Masking styles for transparency (keep as is) */
    -webkit-mask-image: radial-gradient(circle, rgba(255, 255, 255, 1) 50%, rgba(255, 255, 255, 0) 100%);
    mask-image: radial-gradient(circle, rgba(255, 255, 255, 1) 50%, rgba(255, 255, 255, 0) 100%);
}

/* Hover effect: Makes the image pop up and glow intensely */
.image-cta:hover img {
    opacity: 1.0;
    cursor: pointer;
    
    /* LIFT EFFECT */
    transform: translateY(-5px); 
    
    /* HOVER GLOW: Use a much more intense drop-shadow for a clear "pop" */
    filter: drop-shadow(0 0 20px rgba(0, 123, 255, 1.0));
}
