/* ============================================================
   Mert Taşımacılık — Modern stylesheet
   ============================================================ */

:root {
    --color-primary: #c1121f;
    --color-primary-dark: #780000;
    --color-accent: #fdf0d5;
    --color-dark: #003049;
    --color-darker: #001d2e;
    --color-text: #2b2d42;
    --color-muted: #6c757d;
    --color-light: #f8f9fa;
    --color-white: #ffffff;
    --color-border: #e9ecef;

    --shadow-sm: 0 2px 6px rgba(0, 0, 0, 0.06);
    --shadow-md: 0 6px 20px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 12px 40px rgba(0, 0, 0, 0.12);

    --radius-sm: 6px;
    --radius-md: 12px;
    --radius-lg: 20px;

    --font-sans: 'Montserrat', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;

    --header-height: 80px;
    --container-max: 1200px;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: var(--header-height);
}

body {
    font-family: var(--font-sans);
    font-size: 16px;
    line-height: 1.6;
    color: var(--color-text);
    background: var(--color-white);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
}

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

a {
    color: var(--color-primary);
    text-decoration: none;
    transition: color 0.2s ease;
}

a:hover {
    color: var(--color-primary-dark);
}

.container {
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0 24px;
}

/* ============================================================
   Header / Navigation
   ============================================================ */
.site-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: var(--header-height);
    background: rgba(255, 255, 255, 0.97);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    box-shadow: var(--shadow-sm);
    z-index: 1000;
    transition: box-shadow 0.3s ease;
}

.site-header.scrolled {
    box-shadow: var(--shadow-md);
}

.nav-wrapper {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 100%;
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0 24px;
}

.site-logo img {
    height: 56px;
    width: auto;
}

.nav-menu {
    display: flex;
    align-items: center;
    gap: 8px;
    list-style: none;
}

.nav-menu a {
    display: block;
    padding: 10px 16px;
    font-size: 14px;
    font-weight: 600;
    letter-spacing: 0.4px;
    color: var(--color-dark);
    text-transform: uppercase;
    border-radius: var(--radius-sm);
    transition: all 0.25s ease;
}

.nav-menu a:hover,
.nav-menu a.active {
    color: var(--color-primary);
    background: var(--color-accent);
}

.nav-toggle {
    display: none;
    flex-direction: column;
    justify-content: center;
    width: 44px;
    height: 44px;
    padding: 0;
    background: transparent;
    border: none;
    cursor: pointer;
    gap: 5px;
}

.nav-toggle span {
    display: block;
    width: 26px;
    height: 3px;
    margin: 0 auto;
    background: var(--color-dark);
    border-radius: 2px;
    transition: all 0.3s ease;
}

.nav-toggle.is-open span:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
}

.nav-toggle.is-open span:nth-child(2) {
    opacity: 0;
}

.nav-toggle.is-open span:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
}

/* ============================================================
   Hero
   ============================================================ */
.hero {
    position: relative;
    min-height: 100vh;
    padding-top: var(--header-height);
    background: linear-gradient(135deg, var(--color-darker) 0%, var(--color-dark) 100%);
    color: var(--color-white);
    overflow: hidden;
    display: flex;
    align-items: center;
}

.hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image:
        radial-gradient(circle at 20% 30%, rgba(193, 18, 31, 0.18), transparent 50%),
        radial-gradient(circle at 80% 70%, rgba(253, 240, 213, 0.08), transparent 50%);
    pointer-events: none;
}

.hero-content {
    position: relative;
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 60px 24px;
    display: grid;
    grid-template-columns: 1.1fr 1fr;
    gap: 60px;
    align-items: center;
    z-index: 1;
}

.hero-text h1 {
    font-size: clamp(2rem, 5vw, 3.5rem);
    font-weight: 800;
    line-height: 1.15;
    margin-bottom: 20px;
    letter-spacing: -0.5px;
}

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

.hero-text p {
    font-size: clamp(1rem, 1.6vw, 1.2rem);
    color: rgba(255, 255, 255, 0.85);
    margin-bottom: 32px;
    max-width: 540px;
}

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

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 14px 28px;
    font-family: inherit;
    font-size: 15px;
    font-weight: 600;
    letter-spacing: 0.3px;
    text-transform: uppercase;
    border: 2px solid transparent;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: all 0.25s ease;
}

.btn-primary {
    background: var(--color-primary);
    color: var(--color-white);
}

.btn-primary:hover {
    background: var(--color-primary-dark);
    color: var(--color-white);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.btn-outline {
    background: transparent;
    color: var(--color-white);
    border-color: rgba(255, 255, 255, 0.4);
}

.btn-outline:hover {
    background: rgba(255, 255, 255, 0.1);
    color: var(--color-white);
    border-color: var(--color-white);
}

.hero-image {
    position: relative;
    display: flex;
    justify-content: center;
}

.hero-image img {
    max-width: 100%;
    height: auto;
    filter: drop-shadow(0 20px 40px rgba(0, 0, 0, 0.35));
    animation: float 6s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-12px); }
}

.hero-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    margin-top: 48px;
    padding-top: 32px;
    border-top: 1px solid rgba(255, 255, 255, 0.15);
}

.stat-item .stat-number {
    font-size: clamp(1.6rem, 3vw, 2.4rem);
    font-weight: 800;
    color: var(--color-accent);
    line-height: 1;
}

.stat-item .stat-label {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.7);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-top: 6px;
}

/* ============================================================
   Generic section
   ============================================================ */
.section {
    padding: 100px 0;
    position: relative;
}

.section-light {
    background: var(--color-light);
}

.section-dark {
    background: var(--color-darker);
    color: var(--color-white);
}

.section-header {
    text-align: center;
    margin-bottom: 60px;
}

.section-eyebrow {
    display: inline-block;
    font-size: 13px;
    font-weight: 700;
    color: var(--color-primary);
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 12px;
}

.section-dark .section-eyebrow {
    color: var(--color-accent);
}

.section-title {
    font-size: clamp(1.8rem, 3.6vw, 2.6rem);
    font-weight: 800;
    color: var(--color-dark);
    line-height: 1.2;
    margin-bottom: 16px;
}

.section-dark .section-title {
    color: var(--color-white);
}

.section-subtitle {
    font-size: 1.05rem;
    color: var(--color-muted);
    max-width: 700px;
    margin: 0 auto;
}

.section-dark .section-subtitle {
    color: rgba(255, 255, 255, 0.75);
}

/* ============================================================
   About
   ============================================================ */
.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}

.about-text p {
    margin-bottom: 16px;
    color: var(--color-text);
    line-height: 1.75;
}

.about-text p:first-of-type {
    font-size: 1.1rem;
    color: var(--color-dark);
    font-weight: 500;
}

.about-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    margin-top: 32px;
}

.about-badges img {
    height: 90px;
    width: auto;
    border-radius: var(--radius-sm);
    box-shadow: var(--shadow-sm);
    transition: transform 0.3s ease;
}

.about-badges img:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
}

.about-visual {
    position: relative;
    padding: 20px;
}

.about-visual::before {
    content: '';
    position: absolute;
    top: 0;
    left: 20px;
    right: 0;
    bottom: 20px;
    background: var(--color-primary);
    border-radius: var(--radius-lg);
    z-index: 0;
}

.about-visual img {
    position: relative;
    z-index: 1;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
}

/* ============================================================
   Services
   ============================================================ */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 28px;
}

.service-card {
    padding: 36px 28px;
    background: var(--color-white);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    text-align: center;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--color-primary);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.35s ease;
}

.service-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-lg);
    border-color: transparent;
}

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

.service-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--color-accent);
    border-radius: 50%;
    transition: background 0.3s ease;
}

.service-card:hover .service-icon {
    background: var(--color-primary);
}

.service-icon img {
    width: 44px;
    height: 44px;
    object-fit: contain;
    transition: filter 0.3s ease;
}

.service-card:hover .service-icon img {
    filter: brightness(0) invert(1);
}

.service-card h3 {
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--color-dark);
    margin-bottom: 10px;
    line-height: 1.4;
}

.service-card p {
    font-size: 0.92rem;
    color: var(--color-muted);
}

/* ============================================================
   References / Portfolio
   ============================================================ */
.references-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 20px;
}

.reference-item {
    aspect-ratio: 1;
    background: var(--color-white);
    border-radius: var(--radius-md);
    overflow: hidden;
    position: relative;
    box-shadow: var(--shadow-sm);
    transition: all 0.3s ease;
    cursor: pointer;
}

.reference-item:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-lg);
}

.reference-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.reference-item:hover img {
    transform: scale(1.08);
}

.reference-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0, 29, 46, 0.95), transparent 60%);
    display: flex;
    align-items: flex-end;
    padding: 20px;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.reference-item:hover .reference-overlay {
    opacity: 1;
}

.reference-overlay h4 {
    color: var(--color-white);
    font-size: 1rem;
    font-weight: 600;
}

/* ============================================================
   Branches + Map
   ============================================================ */
.branches-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 24px;
    margin-bottom: 50px;
}

.branch-card {
    padding: 30px 26px;
    background: var(--color-white);
    border-radius: var(--radius-md);
    border-left: 4px solid var(--color-primary);
    box-shadow: var(--shadow-sm);
    transition: all 0.25s ease;
}

.section-dark .branch-card {
    background: rgba(255, 255, 255, 0.06);
    border-left-color: var(--color-accent);
    color: var(--color-white);
    box-shadow: none;
}

.branch-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
}

.branch-card h3 {
    font-size: 1.2rem;
    font-weight: 700;
    margin-bottom: 14px;
    color: var(--color-dark);
}

.section-dark .branch-card h3 {
    color: var(--color-accent);
}

.branch-card .branch-info {
    font-size: 0.92rem;
    line-height: 1.7;
    color: var(--color-muted);
    margin-bottom: 18px;
}

.section-dark .branch-card .branch-info {
    color: rgba(255, 255, 255, 0.8);
}

.branch-card .branch-info strong {
    color: var(--color-dark);
}

.section-dark .branch-card .branch-info strong {
    color: var(--color-white);
}

.branch-action {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    font-weight: 600;
    color: var(--color-primary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    cursor: pointer;
    background: none;
    border: none;
    padding: 0;
    font-family: inherit;
}

.section-dark .branch-action {
    color: var(--color-accent);
}

.branch-action:hover {
    color: var(--color-primary-dark);
}

.section-dark .branch-action:hover {
    color: var(--color-white);
}

.branch-action svg {
    width: 16px;
    height: 16px;
}

#map {
    width: 100%;
    height: 450px;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg);
    overflow: hidden;
    z-index: 1;
}

/* Leaflet popup customization */
.leaflet-popup-content-wrapper {
    border-radius: var(--radius-sm);
    box-shadow: var(--shadow-md);
}

.leaflet-popup-content {
    margin: 14px 18px;
    font-family: var(--font-sans);
    font-size: 14px;
    line-height: 1.5;
}

.leaflet-popup-content strong {
    display: block;
    color: var(--color-primary);
    font-size: 15px;
    margin-bottom: 4px;
}

/* ============================================================
   Contact
   ============================================================ */
.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: start;
}

.contact-info-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.contact-info-item {
    display: flex;
    gap: 18px;
    padding: 20px;
    background: var(--color-white);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
    transition: transform 0.25s ease;
}

.contact-info-item:hover {
    transform: translateX(6px);
}

.contact-info-icon {
    flex-shrink: 0;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--color-accent);
    color: var(--color-primary);
    border-radius: 50%;
}

.contact-info-icon svg {
    width: 22px;
    height: 22px;
}

.contact-info-text h4 {
    font-size: 1rem;
    font-weight: 700;
    color: var(--color-dark);
    margin-bottom: 4px;
}

.contact-info-text p,
.contact-info-text a {
    font-size: 0.92rem;
    color: var(--color-muted);
    line-height: 1.6;
}

.contact-form {
    background: var(--color-white);
    padding: 36px;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-md);
}

.form-group {
    margin-bottom: 18px;
}

.form-group label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: var(--color-dark);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 8px;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 12px 16px;
    font-family: inherit;
    font-size: 15px;
    color: var(--color-text);
    background: var(--color-light);
    border: 2px solid transparent;
    border-radius: var(--radius-sm);
    transition: all 0.25s ease;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    background: var(--color-white);
    border-color: var(--color-primary);
    box-shadow: 0 0 0 4px rgba(193, 18, 31, 0.1);
}

.form-group textarea {
    min-height: 130px;
    resize: vertical;
}

.form-submit {
    width: 100%;
    padding: 16px;
    font-size: 14px;
}

.form-message {
    margin-top: 16px;
    padding: 12px 16px;
    border-radius: var(--radius-sm);
    font-size: 14px;
    display: none;
}

.form-message.success {
    background: #d1e7dd;
    color: #0a3622;
    display: block;
}

.form-message.error {
    background: #f8d7da;
    color: #58151c;
    display: block;
}

/* ============================================================
   Footer
   ============================================================ */
.site-footer {
    background: var(--color-darker);
    color: rgba(255, 255, 255, 0.7);
    padding: 50px 0 24px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.2fr 1fr 1fr;
    gap: 50px;
    margin-bottom: 40px;
}

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

.footer-col p,
.footer-col li {
    font-size: 0.9rem;
    line-height: 1.8;
}

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

.footer-col a {
    color: rgba(255, 255, 255, 0.7);
    transition: color 0.2s ease;
}

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

.footer-logo {
    height: 60px;
    margin-bottom: 18px;
    filter: brightness(0) invert(1);
}

.footer-bottom {
    text-align: center;
    padding-top: 24px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.5);
}

/* ============================================================
   Scroll-up button
   ============================================================ */
.scroll-top {
    position: fixed;
    bottom: 24px;
    right: 24px;
    width: 48px;
    height: 48px;
    background: var(--color-primary);
    color: var(--color-white);
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--shadow-lg);
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transition: all 0.3s ease;
    z-index: 999;
}

.scroll-top.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.scroll-top:hover {
    background: var(--color-primary-dark);
    transform: translateY(-3px);
}

.scroll-top svg {
    width: 22px;
    height: 22px;
}

/* ============================================================
   Reveal-on-scroll animation
   ============================================================ */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal.in-view {
    opacity: 1;
    transform: translateY(0);
}

/* ============================================================
   Responsive
   ============================================================ */
@media (max-width: 992px) {
    .hero-content,
    .about-grid,
    .contact-grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .hero {
        min-height: auto;
        padding: calc(var(--header-height) + 40px) 0 60px;
    }

    .hero-image {
        order: -1;
        max-width: 380px;
        margin: 0 auto;
    }

    .about-visual {
        max-width: 500px;
        margin: 0 auto;
    }

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

    .section {
        padding: 70px 0;
    }
}

@media (max-width: 768px) {
    :root {
        --header-height: 70px;
    }

    .nav-toggle {
        display: flex;
    }

    .nav-menu {
        position: fixed;
        top: var(--header-height);
        left: 0;
        right: 0;
        flex-direction: column;
        align-items: stretch;
        gap: 0;
        padding: 16px 0;
        background: var(--color-white);
        box-shadow: var(--shadow-md);
        transform: translateY(-120%);
        transition: transform 0.35s ease;
        max-height: calc(100vh - var(--header-height));
        overflow-y: auto;
    }

    .nav-menu.is-open {
        transform: translateY(0);
    }

    .nav-menu a {
        padding: 16px 24px;
        font-size: 15px;
        border-radius: 0;
        border-bottom: 1px solid var(--color-border);
    }

    .site-logo img {
        height: 44px;
    }

    .hero-stats {
        grid-template-columns: 1fr;
        gap: 20px;
        text-align: center;
    }

    .stat-item {
        padding-bottom: 18px;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    }

    .stat-item:last-child {
        border-bottom: none;
    }

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

    .footer-logo {
        margin: 0 auto 18px;
    }

    .contact-form {
        padding: 24px;
    }

    .contact-info-item {
        padding: 16px;
    }

    #map {
        height: 360px;
    }

    .about-badges {
        justify-content: center;
    }

    .scroll-top {
        bottom: 16px;
        right: 16px;
    }
}

@media (max-width: 480px) {
    .hero-buttons {
        flex-direction: column;
        width: 100%;
    }

    .hero-buttons .btn {
        width: 100%;
    }

    .section-header {
        margin-bottom: 40px;
    }

    .container {
        padding: 0 16px;
    }
}

/* ============================================================
   Print-friendly
   ============================================================ */
@media print {
    .site-header,
    .scroll-top,
    .hero-buttons,
    .contact-form {
        display: none;
    }
}
