/* 
   Theme: 4K Mühendislik - Dark & Turquoise
   Font: Inter
*/

:root {
    --color-primary: #00E5FF;
    /* Cyan/Teal */
    --color-primary-dark: #00B8CC;
    --color-secondary: #0F172A;
    /* Dark Navy */
    --color-bg: #0B0F19;
    /* Very Dark */
    --color-surface: #1E293B;
    /* Slightly lighter for cards */
    --color-text: #F1F5F9;
    --color-text-muted: #94A3B8;
    --border-radius: 12px;
    --container-width: 1200px;
    --header-height: 80px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--color-bg);
    color: var(--color-text);
    line-height: 1.6;
    overflow-x: hidden;
}

a {
    text-decoration: none;
    color: inherit;
    transition: color 0.3s;
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
    display: block;
}

.container {
    width: 90%;
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 15px;
}

/* Typography */
h1,
h2,
h3,
h4,
h5,
h6 {
    color: #fff;
    line-height: 1.2;
    margin-bottom: 1rem;
}

h2 {
    font-size: 2.5rem;
    font-weight: 700;
    text-align: center;
}

p {
    margin-bottom: 1rem;
    color: var(--color-text-muted);
}

.section-header {
    text-align: center;
    margin-bottom: 3rem;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

.section-header p {
    font-size: 1.2rem;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 12px 28px;
    border-radius: 30px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.btn-primary {
    background-color: var(--color-primary);
    color: var(--color-secondary);
}

.btn-primary:hover {
    background-color: var(--color-primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 229, 255, 0.3);
}

.btn-outline {
    border-color: var(--color-primary);
    color: var(--color-primary);
    background: transparent;
}

.btn-outline:hover {
    background-color: rgba(0, 229, 255, 0.1);
    transform: translateY(-2px);
}

/* Header */
.header {
    background-color: rgba(15, 23, 42, 0.95);
    height: var(--header-height);
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    backdrop-filter: blur(10px);
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.3);
    display: flex;
    align-items: center;
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 1.5rem;
    font-weight: 600;
    letter-spacing: -0.5px;
    color: #fff;
}

.nav-menu ul {
    display: flex;
    gap: 2rem;
    align-items: center;
}

.nav-menu a {
    font-weight: 500;
    font-size: 0.95rem;
}

.nav-menu a:hover {
    color: var(--color-primary);
}

.btn-nav {
    background-color: var(--color-primary);
    color: var(--color-secondary) !important;
    padding: 8px 20px;
    border-radius: 20px;
}

.btn-nav:hover {
    background-color: var(--color-primary-dark);
}

/* Dropdown */
.dropdown {
    position: relative;
}

.dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    background-color: var(--color-secondary);
    min-width: 180px;
    border-radius: 8px;
    padding: 10px 0;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.3s ease;
    display: block !important;
    /* Override flex */
}

.dropdown:hover .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-menu li {
    display: block;
}

.dropdown-menu a {
    display: block;
    padding: 10px 20px;
    color: var(--color-text-muted);
}

.dropdown-menu a:hover {
    background-color: rgba(255, 255, 255, 0.05);
    color: var(--color-primary);
}

.arrow {
    font-size: 0.7em;
    margin-left: 5px;
}

/* Mobile Menu */
.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    flex-direction: column;
    gap: 5px;
}

.mobile-menu-btn span {
    width: 25px;
    height: 3px;
    background-color: #fff;
    border-radius: 2px;
}

/* Hero Section */
.hero-section {
    position: relative;
    height: 100vh;
    min-height: 600px;
    display: flex;
    align-items: center;
    padding-top: var(--header-height);
    background-image: url('../img/hero-new.png');
    /* Updated path */
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
}

.hero-bg-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(11, 15, 25, 0.95) 0%, rgba(15, 23, 42, 0.8) 100%);
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 800px;
}

.hero-content h1 {
    font-size: 3.5rem;
    margin-bottom: 1.5rem;
    background: linear-gradient(to right, #fff, var(--color-primary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero-subtitle {
    font-size: 1.25rem;
    margin-bottom: 2.5rem;
    max-width: 600px;
}

.hero-actions {
    display: flex;
    gap: 1rem;
    margin-bottom: 3rem;
}

.hero-features {
    display: flex;
    gap: 2rem;
    flex-wrap: wrap;
}

.feature-item {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 500;
}

.check-icon {
    color: var(--color-primary);
    background: rgba(0, 229, 255, 0.1);
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
}

/* Sections */
.section {
    padding: 100px 0;
}

/* Services */
/* Services */
.services-section {
    position: relative;
    background-image: linear-gradient(rgba(11, 15, 25, 0.9), rgba(11, 15, 25, 0.8)), url('../img/services-bg.jpg');
    background-size: cover;
    background-attachment: fixed;
    background-position: center;
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    position: relative;
    z-index: 2;
}

.service-card {
    background-color: rgba(30, 41, 59, 0.7);
    /* More transparent to show bg */
    padding: 2rem;
    border-radius: var(--border-radius);
    transition: transform 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(5px);
}

.service-card:hover {
    transform: translateY(-10px);
    border-color: var(--color-primary);
    background-color: rgba(30, 41, 59, 0.9);
}

.service-icon {
    font-size: 2.5rem;
    margin-bottom: 1.5rem;
}

.service-card h3 {
    margin-bottom: 1rem;
    color: #fff;
}

/* Projects */
.projects-section {
    position: relative;
    background-image: linear-gradient(rgba(15, 23, 42, 0.9), rgba(15, 23, 42, 0.8)), url('../img/projects-bg.jpg');
    background-size: cover;
    background-attachment: fixed;
    background-position: center;
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 2rem;
}

.project-item {
    background-color: var(--color-bg);
    border-radius: var(--border-radius);
    overflow: hidden;
    transition: transform 0.3s;
    position: relative;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.project-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.project-img {
    height: 250px;
    overflow: hidden;
    position: relative;
}

.project-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s;
}

.project-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(15, 23, 42, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s;
}

.project-item:hover .project-overlay {
    opacity: 1;
}

.project-item:hover .project-img img {
    transform: scale(1.1);
}

.btn-sm {
    padding: 8px 20px;
    font-size: 0.9rem;
}

.project-info {
    padding: 1.5rem;
}

.project-category {
    font-size: 0.8rem;
    text-transform: uppercase;
    color: var(--color-primary);
    letter-spacing: 1px;
    display: block;
    margin-bottom: 0.5rem;
}

/* About */
/* About Single Window Layout */
.about-section {
    position: relative;
    padding: 100px 0;
    /* Use the subtle engineering texture for section background */
    background-image: url('../img/bg-texture.png');
    background-size: cover;
    background-attachment: fixed;
    background-blend-mode: overlay;
    background-color: rgba(11, 15, 25, 0.95);
}

.about-window {
    background-color: var(--color-surface);
    border-radius: 20px;
    padding: 4rem;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.05);
    position: relative;
    overflow: hidden;
}

/* Decorative top bar for the window */
.about-window::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, var(--color-primary), transparent);
}

.about-block {
    display: flex;
    align-items: center;
    gap: 3rem;
    margin-bottom: 4rem;
    background: transparent;
    padding: 0;
    border: none;
    box-shadow: none;
}

.about-block:last-child {
    margin-bottom: 0;
}

.about-block.reverse {
    flex-direction: row-reverse;
}

.about-text {
    flex: 1;
    background: transparent;
    padding: 0;
    border: none;
    box-shadow: none;
}

.about-text h2 {
    font-size: 2rem;
    margin-bottom: 1rem;
    color: var(--color-primary);
}

/* Optimized Images as requested */
.about-image {
    flex: 0 0 40%;
    /* Fixed width ratio */
    border-radius: 12px;
    overflow: hidden;
    height: 250px;
    /* Reduced height for optimization */
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.about-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s;
}

.about-block:hover .about-image img {
    transform: scale(1.05);
}

@media (max-width: 900px) {
    .about-window {
        padding: 2rem;
    }

    .about-block,
    .about-block.reverse {
        flex-direction: column;
        gap: 1.5rem;
    }

    .about-image {
        width: 100%;
        height: 200px;
    }
}

/* Contact */
.contact-section {
    background-color: var(--color-secondary);
}

.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    margin-bottom: 4rem;
}

.contact-item {
    margin-bottom: 2rem;
}

.contact-item h3 {
    color: var(--color-primary);
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
}

.contact-form-wrapper {
    background-color: var(--color-surface);
    padding: 2rem;
    border-radius: var(--border-radius);
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 12px;
    background-color: var(--color-bg);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    color: #fff;
    font-family: inherit;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--color-primary);
}

.checkbox-group {
    display: flex;
    align-items: center;
    gap: 10px;
}

.checkbox-group input {
    width: auto;
}

/* Footer */
.footer {
    background-color: #05080f;
    padding: 4rem 0 0;
    font-size: 0.9rem;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 3rem;
    margin-bottom: 3rem;
}

.footer-col h3 {
    color: #fff;
    margin-bottom: 1.5rem;
    font-size: 1.1rem;
}

.footer-col ul li {
    margin-bottom: 0.8rem;
}

.footer-col ul li a:hover {
    color: var(--color-primary);
    padding-left: 5px;
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    padding: 1.5rem 0;
    text-align: center;
    color: #666;
}

/* Responsive */
@media (max-width: 768px) {
    .header-container {
        padding: 0 20px;
    }

    .mobile-menu-btn {
        display: flex;
        z-index: 1001;
    }

    .nav-menu {
        position: fixed;
        top: 0;
        right: -100%;
        width: 80%;
        height: 100vh;
        background-color: var(--color-secondary);
        padding: 5rem 2rem;
        transition: 0.3s ease;
        box-shadow: -5px 0 20px rgba(0, 0, 0, 0.5);
    }

    .nav-menu.active {
        right: 0;
    }

    .nav-menu ul {
        flex-direction: column;
        align-items: flex-start;
    }

    .dropdown-menu {
        position: static;
        opacity: 1;
        visibility: visible;
        transform: none;
        background-color: transparent;
        box-shadow: none;
        padding-left: 1rem;
        display: none !important;
    }

    .dropdown.active .dropdown-menu {
        display: block !important;
    }

    .hero-content h1 {
        font-size: 2.5rem;
    }

    .contact-grid {
        grid-template-columns: 1fr;
    }
}

/* Toast Notifications */
#toast-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 9999;
}

.toast {
    background-color: var(--color-surface);
    color: #fff;
    padding: 16px 24px;
    border-radius: 8px;
    margin-bottom: 10px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    border-left: 4px solid var(--color-primary);
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 300px;
    opacity: 0;
    transform: translateX(100%);
    transition: all 0.3s ease;
}

.toast.show {
    opacity: 1;
    transform: translateX(0);
}

.toast.success {
    border-left-color: #2ecc71;
}

.toast.danger {
    border-left-color: #e74c3c;
}

.toast-icon {
    font-size: 1.2rem;
}