
/*
Theme Name: Dünya Hidrolik
Theme URI: https://www.dunyahidrolik.com.tr/
Author: Dünya Hidrolik
Description: Dünya Hidrolik ve Pnömatik WooCommerce teması.
Version: 1.1.0
Text Domain: dunya-hidrolik
*/

/* =========================
   1. GENEL AYARLAR
========================= */

:root {
    --navy: #102b4e;
    --navy-dark: #091c33;
    --blue: #1266b1;
    --blue-light: #eaf4ff;
    --cyan: #25a9e0;
    --white: #ffffff;
    --light: #f3f7fb;
    --text: #26384b;
    --muted: #6b7c90;
    --border: #dfe7f0;
    --shadow: 0 8px 24px rgba(16, 43, 78, 0.10);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 25px;
}

body {
    margin: 0;
    font-family: Arial, Helvetica, sans-serif;
    color: var(--text);
    background: var(--white);
    line-height: 1.6;
}

img {
    display: block;
    max-width: 100%;
    height: auto;
}

a {
    color: var(--blue);
    text-decoration: none;
    transition: color 0.2s ease, background 0.2s ease;
}

button,
input,
select,
textarea {
    font: inherit;
}

.container,
.header-inner,
.nav-inner {
    width: min(1200px, 92%);
    margin-left: auto;
    margin-right: auto;
}

/* =========================
   2. ÜST BİLGİ ŞERİDİ
========================= */

.topline {
    padding: 8px 4%;
    color: var(--white);
    background: var(--navy-dark);
    text-align: center;
    font-size: 13px;
    letter-spacing: 0.2px;
}

/* =========================
   3. HEADER
========================= */

.site-header {
    position: relative;
    z-index: 1000;
    background: var(--white);
    border-bottom: 1px solid var(--border);
}

.header-inner {
    min-height: 88px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.brand {
    display: inline-block;
    color: var(--navy);
    font-size: 25px;
    font-weight: 800;
    line-height: 1.2;
    letter-spacing: -0.5px;
}

.brand span {
    color: var(--blue);
}

.brand small {
    display: block;
    margin-top: 5px;
    font-size: 10px;
    letter-spacing: 2.2px;
    font-weight: 700;
}

.header-links {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 18px;
    flex-wrap: wrap;
}

.header-links > a:not(.btn) {
    color: var(--navy);
    font-weight: 700;
    font-size: 14px;
}

/* =========================
   4. BUTONLAR
========================= */

.btn,
button.button,
a.button,
.woocommerce button.button,
.woocommerce a.button,
.woocommerce input.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 42px;
    padding: 11px 17px;
    border: 1px solid var(--blue);
    border-radius: 6px;
    background: var(--blue);
    color: var(--white);
    font-weight: 700;
    font-size: 14px;
    text-align: center;
    cursor: pointer;
    transition: background 0.2s ease, transform 0.2s ease;
}

.btn:hover,
button.button:hover,
a.button:hover,
.woocommerce button.button:hover,
.woocommerce a.button:hover,
.woocommerce input.button:hover {
    color: var(--white);
    background: var(--navy);
    border-color: var(--navy);
}

.btn:active {
    transform: translateY(1px);
}

.btn-light {
    background: var(--white);
    border-color: var(--white);
    color: var(--navy);
}

.btn-light:hover {
    background: var(--blue-light);
    border-color: var(--blue-light);
    color: var(--navy);
}

/* =========================
   5. ANA MENÜ
========================= */

.navbar {
    position: relative;
    z-index: 1001;
    background: var(--navy);
}

.nav-inner {
    display: flex;
    align-items: stretch;
    flex-wrap: wrap;
    gap: 0;
}

.nav-inner > a {
    display: flex;
    align-items: center;
    min-height: 48px;
    padding: 12px 15px;
    color: var(--white);
    font-size: 14px;
    font-weight: 600;
    white-space: nowrap;
}

.nav-inner > a:hover,
.nav-inner > a:focus {
    color: var(--white);
    background: var(--blue);
}

/* =========================
   6. AÇILIR ALT KATEGORİLER
========================= */

.menu-item-dropdown {
    position: relative;
    display: flex;
    align-items: stretch;
}

.menu-parent {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 48px;
    padding: 12px 15px;
    color: var(--white);
    font-size: 14px;
    font-weight: 600;
    white-space: nowrap;
}

.menu-parent:hover,
.menu-parent:focus,
.menu-item-dropdown:hover > .menu-parent,
.menu-item-dropdown:focus-within > .menu-parent {
    color: var(--white);
    background: var(--blue);
}

.dropdown-arrow {
    display: inline-block;
    font-size: 12px;
    transition: transform 0.2s ease;
}

.menu-item-dropdown:hover .dropdown-arrow,
.menu-item-dropdown:focus-within .dropdown-arrow {
    transform: rotate(180deg);
}

.submenu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 235px;
    max-width: 300px;
    padding: 7px 0;
    background: var(--white);
    border: 1px solid var(--border);
    border-top: 3px solid var(--cyan);
    border-radius: 0 0 8px 8px;
    box-shadow: 0 12px 28px rgba(9, 28, 51, 0.18);
    z-index: 9999;
}

/* Fare ile gelince veya klavyeyle odaklanınca açılır */
.menu-item-dropdown:hover > .submenu,
.menu-item-dropdown:focus-within > .submenu {
    display: block;
}

.submenu a {
    display: block;
    padding: 11px 17px;
    color: var(--text);
    background: var(--white);
    font-size: 14px;
    line-height: 1.4;
    white-space: normal;
}

.submenu a:hover,
.submenu a:focus {
    padding-left: 22px;
    color: var(--blue);
    background: var(--blue-light);
}

/* =========================
   7. ANA VİTRİN
========================= */

.hero {
    position: relative;
    overflow: hidden;
    padding: 76px 0;
    color: var(--white);
    background: linear-gradient(
        115deg,
        var(--navy-dark) 0%,
        var(--navy) 45%,
        var(--blue) 78%,
        var(--cyan) 100%
    );
}

.hero h1 {
    max-width: 780px;
    margin: 0 0 20px;
    color: var(--white);
    font-size: clamp(32px, 5vw, 54px);
    line-height: 1.14;
    font-weight: 800;
    letter-spacing: -1px;
}

.hero p {
    max-width: 650px;
    margin: 0 0 27px;
    color: #e7f2ff;
    font-size: 18px;
    line-height: 1.7;
}

.hero .btn {
    margin: 0 8px 8px 0;
}

/* =========================
   8. AVANTAJLAR
========================= */

.benefits {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
    padding-top: 24px;
    padding-bottom: 24px;
    background: var(--white);
}

.benefit {
    padding: 14px;
    border: 1px solid var(--border);
    border-radius: 8px;
    color: var(--navy);
    background: var(--light);
    text-align: center;
    font-size: 15px;
    font-weight: 700;
}

/* =========================
   9. BÖLÜMLER
========================= */

.section {
    padding-top: 54px;
    padding-bottom: 54px;
}

.section-alt {
    background: var(--light);
}

.section-title {
    margin: 0 0 10px;
    color: var(--navy);
    font-size: clamp(25px, 3vw, 34px);
    line-height: 1.25;
    font-weight: 800;
}

.section-intro {
    margin: 0 0 27px;
    color: var(--muted);
    font-size: 15px;
}

/* =========================
   10. ÜRÜN ARAMA
========================= */

.search-input {
    display: block;
    width: 100%;
    max-width: 440px;
    min-height: 46px;
    margin-bottom: 28px;
    padding: 12px 15px;
    color: var(--text);
    background: var(--white);
    border: 1px solid #cdd9e6;
    border-radius: 7px;
    outline: none;
}

.search-input:focus {
    border-color: var(--blue);
    box-shadow: 0 0 0 3px rgba(18, 102, 177, 0.12);
}

/* =========================
   11. ÜRÜN KARTLARI
========================= */

.product-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 22px;
}

.product-card {
    min-width: 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: 10px;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.product-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow);
}

.product-image {
    min-height: 215px;
    height: 215px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 22px;
    background: #f6f9fc;
    border-bottom: 1px solid #edf1f6;
    color: var(--muted);
}

.product-image img {
    width: auto;
    max-width: 100%;
    max-height: 175px;
    object-fit: contain;
}

.product-info {
    display: flex;
    flex: 1;
    flex-direction: column;
    padding: 19px;
}

.product-info h3 {
    margin: 0 0 10px;
    color: var(--navy);
    font-size: 18px;
    line-height: 1.4;
    font-weight: 800;
}

.product-info h3 a {
    color: var(--navy);
}

.product-info h3 a:hover {
    color: var(--blue);
}

.product-info p {
    margin: 0 0 12px;
    color: var(--muted);
    font-size: 14px;
    line-height: 1.6;
}

.price {
    margin-top: auto;
    padding-top: 8px;
    padding-bottom: 10px;
    color: var(--blue);
    font-size: 16px;
    font-weight: 800;
}

.product-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: stretch;
    gap: 8px;
    margin-top: 10px;
}

.product-actions .btn {
    flex: 1 1 auto;
    min-height: 40px;
    padding: 9px 11px;
    font-size: 13px;
}

/* =========================
   12. TEKLİF ALANI
========================= */

.quote-banner {
    padding: 38px;
    color: var(--white);
    background: linear-gradient(120deg, var(--navy), var(--blue));
    border-radius: 12px;
    box-shadow: var(--shadow);
}

.quote-banner h2 {
    margin: 0 0 12px;
    color: var(--white);
    font-size: clamp(24px, 3vw, 32px);
    line-height: 1.3;
}

.quote-banner p {
    max-width: 700px;
    margin: 0 0 22px;
    color: #e4effb;
    font-size: 15px;
}

/* =========================
   13. ALT BİLGİ / FOOTER
========================= */

.site-footer {
    padding: 38px 0;
    color: var(--white);
    background: var(--navy-dark);
}

.footer-inner {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 28px;
}

.site-footer strong {
    font-size: 18px;
}

.site-footer p {
    color: #d0deed;
}

.site-footer a {
    color: #b8ddff;
}

.site-footer a:hover {
    color: var(--white);
}

/* =========================
   14. WOOCOMMERCE
========================= */

.woocommerce .woocommerce-breadcrumb {
    margin: 22px auto;
    width: min(1200px, 92%);
    color: var(--muted);
    font-size: 13px;
}

.woocommerce .woocommerce-breadcrumb a {
    color: var(--blue);
}

.woocommerce div.product .product_title {
    color: var(--navy);
    font-weight: 800;
}

.woocommerce div.product p.price,
.woocommerce div.product span.price {
    color: var(--blue);
    font-weight: 800;
}

.woocommerce ul.products li.product {
    padding: 12px;
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: 9px;
}

.woocommerce ul.products li.product img {
    border-radius: 5px;
}

.woocommerce ul.products li.product .woocommerce-loop-product__title {
    color: var(--navy);
    font-size: 16px;
    font-weight: 700;
}

.woocommerce ul.products li.product .price {
    color: var(--blue);
}

.woocommerce .quantity .qty {
    min-height: 40px;
    border: 1px solid var(--border);
    border-radius: 5px;
}

.woocommerce table.shop_table {
    border-color: var(--border);
    border-radius: 7px;
}

.woocommerce table.shop_table th {
    color: var(--navy);
}

.woocommerce-message,
.woocommerce-info {
    border-top-color: var(--blue);
}

.woocommerce-message::before,
.woocommerce-info::before {
    color: var(--blue);
}

.woocommerce form .form-row input.input-text,
.woocommerce form .form-row textarea,
.woocommerce form .form-row select {
    min-height: 43px;
    padding: 10px;
    border: 1px solid #cdd9e6;
    border-radius: 5px;
}

.woocommerce form .form-row textarea {
    min-height: 110px;
}

/* =========================
   15. MOBİL VE TABLET
========================= */

@media (max-width: 900px) {
    .product-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 16px;
    }

    .header-inner {
        gap: 15px;
    }

    .nav-inner > a,
    .menu-parent {
        padding-right: 11px;
        padding-left: 11px;
        font-size: 13px;
    }

    .product-actions .btn {
        flex-basis: 100%;
    }
}

@media (max-width: 760px) {
    .topline {
        font-size: 12px;
    }

    .header-inner {
        min-height: auto;
        padding-top: 18px;
        padding-bottom: 18px;
        align-items: flex-start;
        flex-direction: column;
    }

    .brand {
        font-size: 23px;
    }

    .header-links {
        width: 100%;
        justify-content: space-between;
    }

    .navbar {
        overflow: visible;
    }

    .nav-inner {
        width: 100%;
        flex-direction: column;
        align-items: stretch;
    }

    .nav-inner > a {
        min-height: 44px;
        padding: 12px 4%;
        border-bottom: 1px solid rgba(255, 255, 255, 0.09);
    }

    .menu-item-dropdown {
        display: flex;
        flex-direction: column;
        align-items: stretch;
        width: 100%;
    }

    .menu-parent {
        min-height: 44px;
        justify-content: space-between;
        padding: 12px 4%;
        border-bottom: 1px solid rgba(255, 255, 255, 0.09);
    }

    .submenu {
        position: static;
        display: none;
        width: 100%;
        max-width: none;
        min-width: 0;
        padding: 0;
        background: #f4f8fc;
        border: 0;
        border-left: 3px solid var(--cyan);
        border-radius: 0;
        box-shadow: none;
    }

    /* Dokunmatik cihazlarda alt menüyü açmak için odak desteği */
    .menu-item-dropdown:focus-within > .submenu {
        display: block;
    }

    .submenu a {
        padding: 12px 22px;
        color: var(--navy);
        background: #f4f8fc;
        border-bottom: 1px solid #e4edf6;
    }

    .submenu a:hover,
    .submenu a:focus {
        padding-left: 28px;
        background: var(--blue-light);
    }

    .hero {
        padding: 48px 0;
    }

    .hero p {
        font-size: 16px;
    }

    .benefits {
        grid-template-columns: 1fr;
        gap: 10px;
        padding-top: 18px;
        padding-bottom: 18px;
    }

    .section {
        padding-top: 38px;
        padding-bottom: 38px;
    }

    .footer-inner {
        flex-direction: column;
    }
}

@media (max-width: 480px) {
    .container {
        width: 92%;
    }

    .product-grid {
        grid-template-columns: 1fr;
        gap: 18px;
    }

    .product-image {
        height: 220px;
    }

    .product-info {
        padding: 17px;
    }

    .product-actions .btn {
        flex: 1 1 100%;
    }

    .quote-banner {
        padding: 24px;
    }

    .hero .btn {
        width: 100%;
        margin-right: 0;
    }
}
