:root {
    --primary-color: #0ea5a4;
    --primary-color-rgb: 14, 165, 164;
    --secondary-color: #ff8a3d;
    --secondary-color-rgb: 255, 138, 61;
    --dark-color: #082f3b;
    --surface-color: #eefaf9;
    --soft-orange: #fff4ea;
    --header-height: 90px;
    --extra-font: 'Space Grotesk', sans-serif;
    --body-font: 'Manrope', sans-serif;
    --brand-gradient: linear-gradient(135deg, #082f3b 0%, #0ea5a4 52%, #ff8a3d 100%);
    --brand-gradient-soft: linear-gradient(135deg, rgba(14, 165, 164, 0.08) 0%, rgba(255, 138, 61, 0.12) 100%);
    --brand-shadow: 0 24px 60px rgba(8, 47, 59, 0.12);
}

body,
html {
    margin: 0;
    padding: 0;
    scroll-behavior: smooth;
    font-family: var(--body-font);
    overflow-x: hidden;
    background: linear-gradient(180deg, #f6fbfb 0%, #fff8f2 100%);
    color: #18353f;

    &.active {
        body {
            padding-top: var(--header-height);
        }
    }
}

a {
    text-decoration: none;
    color: inherit;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--extra-font);
    letter-spacing: -0.02em;
}

/* Old generic header styles removed - now handled by .esem-header in header.php */

img {
    max-width: 100%;
    max-height: 100%;
}

@keyframes move_x {
    0% {
        transform: translateX(0px);
    }

    50% {
        transform: translateX(-15px);
    }

    100% {
        transform: translateX(0px);
    }
}

@keyframes move_y {
    0% {
        transform: translateY(0px);
    }

    50% {
        transform: translateY(-15px);
    }

    100% {
        transform: translateY(0px);
    }
}

[data-animation] {
    opacity: 0;

    &.animated {
        opacity: unset;
    }
}

main {

    .main-swiper {
        width: 100%;
    }

    .main-breadcrumb {
        position: relative;

        .breadcrumb-img {
            position: absolute;
            left: 0;
            top: 0;
            width: 100%;
            height: 100%;
            background: url(../img/footer.jpg);
            background-size: 400px 400px;
            opacity: 0.025;
        }

        .breadcrumb-front {
            position: relative;
            z-index: 1;
            padding: 130px 0 60px 0;
            width: 100%;
            height: 100%;
            background-color: rgba(var(--primary-color-rgb), 0.05);
            color: var(--primary-color);

            h1 {
                font-family: var(--extra-font);
            }

            .breadcrumb-nav {
                display: flex;
                justify-content: flex-end;
                align-items: center;
                flex-wrap: wrap;
                gap: 5px;

                a {
                    font-family: var(--extra-font);
                    padding: 5px 10px;
                    white-space: nowrap;
                    font-size: 25px;

                    &::after {
                        content: ">";
                        pointer-events: none;
                        margin-left: 10px;
                        margin-right: -10px;
                        font-weight: normal !important;
                    }

                    &:last-child {
                        color: rgba(var(--primary-color-rgb), 0.5);

                        &:after {
                            content: "";
                        }
                    }
                }
            }
        }
    }

    section {
        position: relative;
        padding: 50px 0;

        .section-header {
            display: block;
            position: relative;
            overflow: hidden;
            margin-bottom: 30px;

            h3 {
                font-weight: 600;
                font-size: 30px;
                color: black;
            }

            h2 {
                font-size: 20px;
                margin-bottom: 0;
                font-weight: bold;
                font-family: var(--extra-font);
                color: var(--primary-color);
            }
        }
    }

    .details__box {
        text-align: center;
        transition: all .3s ease-in-out;
        width: fit-content;
        margin: 0 auto;
        padding: 30px;
        position: relative;

        iconify-icon {
            font-size: 40px;
            color: var(--primary-color)
        }

        h6 {
            font-size: 40px;
            font-weight: 600;
            margin: 20px 0;
        }

        h5 {
            font-size: 15px;
            font-weight: normal;
            margin-bottom: 0;
        }

        &:after {
            position: absolute;
            content: "";
            left: 50%;
            transform: translateX(-50%);
            bottom: 0;
            height: 0.1px;
            background-color: #666;
            width: 0;
            transition: all .3s ease-in-out;
        }

        &:hover {
            transform: scale(1.1);

            &:after {
                width: 100%;
            }
        }
    }

    .contact-zone {
        padding: 0;
        color: white;

        .contact {
            background-color: var(--primary-color);
            border-top: 1px solid var(--primary-color);
            border-bottom: 1px solid var(--primary-color);
            height: 100%;
            transition: all .3s ease-in-out;
            padding: 30px;
            display: flex;
            align-items: center;
            justify-content: center;
            gap: 20px;
            border-right: 0.1px solid rgba(255, 255, 255, 0.25);

            span {
                display: block;
                font-size: 13px;
            }

            h3 {
                font-size: 20px;
                margin: 0;
                line-height: 1;
            }

            iconify-icon {
                font-size: 40px;
            }

            &:hover {
                background-color: white;
                color: var(--primary-color)
            }
        }
    }

    .kurslar {
        .kurs-ara {
            display: flex;
            align-items: center;
            gap: 10px;
            border-bottom: 1px solid rgba(var(--primary-color-rgb), 0.15);
            padding-bottom: 1rem;

            iconify-icon {
                font-size: 36px;
                color: var(--primary-color);
            }

            input {
                border: 2px solid var(--primary-color) !important;
                padding: 10px 20px;
                width: 500px;

                outline: unset !important;
            }
        }

        .kurs {
            position: relative;
            display: flex;
            flex-direction: column;
            gap: 10px;
            border-radius: 10px 30px 10px 30px;
            background-color: rgba(var(--primary-color-rgb), 0.05);
            padding: 20px;
            overflow: hidden;

            .background {
                display: flex;
                align-items: center;
                justify-content: center;
                position: absolute;
                right: 20px;
                bottom: 5px;
                pointer-events: none;
                color: rgba(var(--primary-color-rgb), 0.05);
                font-size: 200px;
                z-index: -1;
                transition: all .3s ease-in-out;
            }

            h2 {
                font-family: var(--extra-font);
                color: var(--primary-color);
                margin-bottom: 0;
            }

            .i {
                display: flex;
                align-items: center;
                gap: 10px;

                iconify-icon {
                    font-size: 20px;
                    color: var(--primary-color);
                }
            }

            &:hover {
                .background {
                    color: rgba(var(--primary-color-rgb), 0.25);
                }
            }
        }
    }

    .contact_form {
        .form-control {
            border: 2px solid var(--primary-color);
            border-radius: 0;
            padding: 10px 20px;
            outline: unset !important;
            box-shadow: unset !important;
        }
    }

}

footer {
    position: relative;
    box-shadow: 0 0 10px 0 rgba(var(--primary-color-rgb), 0.15);

    .footer-background {
        opacity: 0.025;
        top: 0;
        left: 0;
        z-index: -1;
        position: absolute;
        width: 100%;
        height: 100%;
        background-image: url(../img/foot.jpg);
        background-size: 500px 500px;
    }

    .footer-main {
        padding: 100px 0;
        padding-bottom: 50px;
        height: 100%;
        width: 100%;
        background-color: rgba(0, 0, 0, 0);
    }

    .footer-bottom {
        p {
            font-size: 12px;
            text-align: center;
        }
    }

    img {
        height: 150px;
    }

    h5 {
        color: var(--primary-color);
        margin-bottom: 15px;
    }

    .sosyal {
        a {
            background-color: var(--primary-color);
            width: 40px;
            height: 40px;
            display: flex;
            align-items: center;
            justify-content: center;
            font-size: 20px;
            border-radius: 50%;
            color: white;
            transition: all .3s ease-in-out;
            border: 3px solid var(--primary-color);

            &:hover {
                background-color: white;
                color: var(--primary-color);
            }
        }
    }
}

.primary-button,
.secondary-button {
    width: fit-content;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    position: relative;
    overflow: hidden;
    padding: 7.5px 15px;
    border-radius: 50px;
    text-align: center;
    white-space: nowrap;
    background-color: var(--primary-color);
    color: white;
    font-size: 15px;
    transition: all .3s ease-in-out;
    z-index: 1;
    border: 2px solid var(--primary-color) !important;

    &:before {
        transition: all .3s ease-in-out;
        content: "";
        position: absolute;
        left: 0;
        top: 0;
        width: 0;
        height: 100%;
        z-index: -1;
        border-radius: 50px;
        background-color: white;
    }

    &:hover {
        color: var(--primary-color);

        &:before {
            width: 100%;
        }
    }
}

@keyframes move_y {
    0% {
        transform: translateY(0px);
    }

    50% {
        transform: translateY(-10px);
    }

    100% {
        transform: translateY(0px);
    }
}

.header-animated {
    animation: 5s move_y ease-in-out infinite;
}

.secondary-button {
    background-color: white;
    color: var(--primary-color);

    &::before {
        background-color: var(--primary-color);
    }

    &:hover {
        color: white;
    }
}

.loading {
    position: fixed;
    left: 0;
    top: 0;
    z-index: 10;
    width: 100%;
    height: 100%;
    background-color: white;
    display: flex;
    align-items: center;
    justify-content: center;

    img {
        display: block;
        max-height: 256px;
        max-width: 90%;
    }
}

.yukari {
    display: none;
    position: fixed;
    z-index: 5;
    right: 0;
    pointer-events: none;
    top: 50%;
    transform: translateY(-50%);

    .rotated {
        pointer-events: all;
        display: flex;
        align-items: center;
        gap: 10px;
        cursor: pointer;
        font-size: 12px;
        transform: translateX(25%) rotate(-90deg);

        .progress {
            position: relative;
            width: 60px;
            height: 1px;
            transition: all .3s ease;
            background-color: #ccc;
            border-radius: 50px;

            i {
                position: absolute;
                width: 0;
                transition: all .3s ease;
                height: 100%;
                border-radius: 50px;
                background-color: var(--primary-color);
            }
        }

        span {
            color: #ccc;
            transition: all .3s ease;
        }

        &:hover {
            .progress {
                background-color: var(--primary-color);
            }

            span {
                color: var(--primary-color);
            }
        }
    }

    &.in-bg {
        .rotated {
            .progress {
                background-color: white;
            }

            span {
                color: white;
            }

            &:hover {
                .progress {
                    background-color: black;
                }

                span {
                    color: black;
                }
            }
        }
    }
}

#alerts__ {
    z-index: 100;
    position: fixed;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    gap: 10px;
    align-items: center;

    .alert {
        width: fit-content;
        max-width: 350px;
    }
}

@media (max-width: 991px) {
    /* Tablet */
    main .main-breadcrumb .breadcrumb-front {
        padding: 60px 0;
    }

    main .main-breadcrumb .breadcrumb-front h1 {
        font-size: 28px;
    }

    main .main-breadcrumb .breadcrumb-front .breadcrumb-nav a {
        font-size: 18px;
    }

    footer .footer-main {
        padding: 50px 0 30px;
    }

    footer img {
        height: 100px;
    }

    main section {
        padding: 30px 0;
    }
}

@media (max-width: 763px) {

    /* Old mobile header styles removed - now in header.php */

    body {
        padding-top: 0 !important;
    }

    main {
        .contact-zone {
            .contact {
                justify-content: flex-start;

                h3 {
                    font-size: 15px;
                }
            }
        }

        .main-breadcrumb {
            text-align: center;

            .breadcrumb-front {
                padding: 40px 0;

                h1 {
                    font-size: 22px;
                }

                .breadcrumb-nav {
                    justify-content: center;

                    a {
                        font-size: 14px;
                        padding: 3px 5px;
                    }
                }
            }
        }

        section {
            padding: 25px 0;
        }

        .kurslar {
            .kurs-ara {
                flex-direction: column;
                align-items: stretch;

                input {
                    width: 100% !important;
                }
            }
        }
    }

    /* Footer mobil */
    footer {
        .footer-main {
            padding: 30px 0 20px;
        }

        img {
            height: 80px;
            margin-bottom: 15px;
        }

        h5 {
            font-size: 16px;
        }
    }

    /* Butonlar mobil */
    .primary-button,
    .secondary-button {
        padding: 10px 15px;
        font-size: 14px;
    }

    /* Alerts mobil */
    #alerts__ {
        left: 10px;
        right: 10px;
        transform: none;

        .alert {
            max-width: 100%;
            width: 100%;
            font-size: 13px;
        }
    }
}

/* ===========================================
   GENEL MOBİL İYİLEŞTİRMELER
   =========================================== */

/* Tablolar için responsive */
@media (max-width: 768px) {
    .table-responsive {
        font-size: 12px;
    }

    .table th,
    .table td {
        padding: 8px 6px;
        white-space: nowrap;
    }
}

/* Modal mobil iyileştirmeleri */
@media (max-width: 576px) {
    .modal-dialog {
        margin: 10px;
        max-width: calc(100% - 20px);
    }

    .modal-body {
        padding: 15px;
    }

    .modal-header,
    .modal-footer {
        padding: 12px 15px;
    }

    .modal-title {
        font-size: 16px;
    }

    .modal-footer {
        flex-direction: column;
        gap: 10px;
    }

    .modal-footer .btn,
    .modal-footer .primary-button,
    .modal-footer .secondary-button {
        width: 100%;
    }
}

/* Kurs kartları responsive */
@media (max-width: 576px) {
    .kurs-card-buttons {
        flex-direction: column;
    }

    .kurs-card-buttons .flex-1,
    .kurs-card-buttons .primary-button,
    .kurs-card-buttons .secondary-button {
        width: 100%;
    }

    .kurs-card-img {
        height: 140px;
    }

    .kurs-card-title {
        font-size: 16px;
    }

    .kurs-card-text {
        font-size: 13px;
    }

    .kurs-card-info .info-item {
        font-size: 12px;
    }
}

/* Kurs merkezi kartları responsive */
@media (max-width: 576px) {
    .kurs-merkezi-card {
        padding: 20px;
    }

    .kurs-merkezi-card h3 {
        font-size: 16px;
        min-height: auto;
    }

    .kurs-merkezi-icon {
        width: 50px;
        height: 50px;
    }

    .kurs-merkezi-icon iconify-icon {
        font-size: 24px;
    }

    .kurs-merkezi-info .info-row {
        font-size: 12px;
    }

    .kurs-merkezi-buttons {
        flex-wrap: wrap;
    }

    .kurs-merkezi-buttons .flex-grow-1 {
        order: -1;
        width: 100%;
        flex: auto;
    }
}

/* Form elemanları responsive */
@media (max-width: 576px) {
    .form-control,
    .form-select {
        font-size: 14px;
        padding: 10px 12px;
    }

    .form-label {
        font-size: 13px;
    }

    input[type="file"] {
        font-size: 13px;
    }
}

/* Detay box responsive */
@media (max-width: 576px) {
    .kurs-detay-box {
        padding: 12px;
    }

    .kurs-detay-box h6 {
        font-size: 13px;
    }

    .kurs-detay-box p,
    .kurs-detay-box table {
        font-size: 12px;
    }
}

/* Card responsive */
@media (max-width: 576px) {
    .card {
        border-radius: 10px;
    }

    .card-body {
        padding: 15px;
    }

    .card-header {
        padding: 12px 15px;
    }

    .card-title {
        font-size: 16px;
    }
}

/* Alert responsive */
@media (max-width: 576px) {
    .alert {
        padding: 12px 15px;
        font-size: 13px;
    }
}

/* Touch-friendly buton boyutları */
@media (max-width: 576px) {
    .btn {
        min-height: 44px;
        padding: 10px 16px;
    }

    .primary-button,
    .secondary-button {
        min-height: 44px;
        padding: 12px 20px;
    }

    /* İkon butonları */
    .btn-icon {
        min-width: 44px;
        min-height: 44px;
    }
}

/* Details box ve info listesi responsive */
@media (max-width: 576px) {
    .details__box {
        padding: 20px 15px;

        iconify-icon {
            font-size: 30px;
        }

        h6 {
            font-size: 28px;
            margin: 15px 0;
        }

        h5 {
            font-size: 13px;
        }
    }
}

/* İletişim zone responsive */
@media (max-width: 576px) {
    main .contact-zone .contact {
        padding: 20px 15px;
        flex-direction: column;
        text-align: center;

        iconify-icon {
            font-size: 30px;
        }

        h3 {
            font-size: 14px;
        }

        span {
            font-size: 11px;
        }
    }
}

/* Scroll yumuşatma mobil için */
@media (max-width: 768px) {
    * {
        -webkit-tap-highlight-color: transparent;
    }

    body {
        -webkit-overflow-scrolling: touch;
    }
}

/* Container padding ayarları */
@media (max-width: 576px) {
    .container {
        padding-left: 15px;
        padding-right: 15px;
    }
}

/* Row ve column boşluk ayarları */
@media (max-width: 576px) {
    .row {
        --bs-gutter-x: 1rem;
    }

    .g-4 {
        --bs-gutter-y: 1rem;
    }

    .gap-3 {
        gap: 0.75rem !important;
    }

    .gap-4 {
        gap: 1rem !important;
    }
}

/* ========================================
   GENÇLIK VE SPOR THEME REFRESH
   ======================================== */

body::before {
    content: "";
    position: fixed;
    inset: 0;
    background:
        radial-gradient(circle at top right, rgba(var(--secondary-color-rgb), 0.16), transparent 28%),
        radial-gradient(circle at top left, rgba(var(--primary-color-rgb), 0.14), transparent 30%);
    pointer-events: none;
    z-index: -1;
}

.main-breadcrumb .breadcrumb-front {
    background: linear-gradient(135deg, rgba(8, 47, 59, 0.94) 0%, rgba(14, 165, 164, 0.82) 56%, rgba(255, 138, 61, 0.7) 100%);
    color: #fff;
}

.main-breadcrumb .breadcrumb-front h1,
.main-breadcrumb .breadcrumb-front a {
    color: #fff;
}

.main-breadcrumb .breadcrumb-front .breadcrumb-nav a:last-child {
    color: rgba(255, 255, 255, 0.72);
}

main section .section-header h3 {
    color: var(--dark-color);
}

.details__box {
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(12px);
    border-radius: 28px;
    box-shadow: var(--brand-shadow);
}

.contact-zone .contact {
    background: var(--brand-gradient);
    border-top: 1px solid rgba(255, 255, 255, 0.15);
    border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}

.contact-zone .contact:hover {
    background: #ffffff;
    color: var(--dark-color);
}

.footer-main {
    position: relative;
    background: linear-gradient(135deg, rgba(8, 47, 59, 0.97) 0%, rgba(11, 93, 111, 0.94) 45%, rgba(255, 138, 61, 0.9) 100%);
    color: #fff;
}

.footer-background {
    background:
        radial-gradient(circle at left top, rgba(255, 255, 255, 0.14), transparent 25%),
        radial-gradient(circle at right bottom, rgba(255, 255, 255, 0.12), transparent 30%);
}

footer h5 {
    color: #fff;
    letter-spacing: 0.08em;
}

footer a {
    color: rgba(255, 255, 255, 0.86);
}

footer a:hover {
    color: #fff;
}

.footer-bottom {
    background: #fff;
}

.yukari .progress {
    background: var(--brand-gradient);
    box-shadow: 0 10px 30px rgba(var(--primary-color-rgb), 0.28);
}
