﻿/* Altın hesaplayıcı — Hakbilir Toptan görsel dili (altın tonları, yumuşak paneller) */

.irem-calc-page {
    --irem-calc-sidebar-w: 320px;
    --irem-calc-dock-top: 122px;
}

.irem-calc-lede {
    max-width: 38rem;
    margin: 12px auto 0;
    font-size: clamp(0.9375rem, 2vw, 1.05rem);
    line-height: 1.6;
    color: rgba(90, 82, 72, 0.92);
}

.page-title .irem-calc-lede {
    margin-bottom: 0;
}

.irem-calc {
    position: relative;
    padding-top: clamp(28px, 5vw, 48px);
    padding-bottom: clamp(56px, 8vw, 100px);
    background:
        radial-gradient(120% 80% at 50% -15%, rgba(180, 157, 103, 0.14) 0%, transparent 55%),
        linear-gradient(180deg, #faf8f4 0%, #f3efe8 100%);
}

.irem-calc-main .auto-container {
    max-width: 1200px;
}

/* Özet paneli — ortak yüzey */
.irem-calc-summary {
    padding: clamp(20px, 3vw, 28px) clamp(18px, 3vw, 24px);
    border-radius: 20px;
    background:
        linear-gradient(145deg, rgba(255, 255, 255, 0.95) 0%, rgba(252, 250, 246, 0.98) 100%);
    border: 1px solid rgba(180, 157, 103, 0.22);
    box-shadow:
        0 4px 6px rgba(19, 22, 21, 0.04),
        0 18px 44px rgba(40, 30, 20, 0.09),
        inset 0 1px 0 rgba(255, 255, 255, 0.85);
}

/* Masaüstü: sol sabit şerit */
@media (min-width: 992px) {
    .irem-calc-page .page-title .auto-container {
        padding-left: calc(var(--irem-calc-sidebar-w) + clamp(16px, 2.5vw, 32px));
        padding-right: clamp(16px, 3vw, 28px);
        max-width: none;
        box-sizing: border-box;
    }

    .irem-calc {
        padding-top: 0;
        padding-bottom: 0;
    }

    .irem-calc-summary--dock {
        position: fixed;
        left: 0;
        top: var(--irem-calc-dock-top);
        bottom: 0;
        z-index: 85;
        width: var(--irem-calc-sidebar-w);
        margin: 0;
        padding-top: 24px;
        padding-bottom: 28px;
        border-radius: 0;
        border-left: none;
        border-top: none;
        border-bottom: none;
        overflow-x: hidden;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
        box-shadow: 4px 0 28px rgba(19, 22, 21, 0.08);
    }

    .irem-calc-main {
        margin-left: var(--irem-calc-sidebar-w);
        padding-top: clamp(28px, 5vw, 48px);
        padding-bottom: clamp(56px, 8vw, 100px);
        min-height: min(100vh, 720px);
    }

    .irem-calc-summary--dock .irem-calc-summary__totals {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .irem-calc-summary--dock .irem-calc-total__value {
        font-size: clamp(1.35rem, 2.5vw, 1.65rem);
    }
}

/* Mobil / dar tablet: panel üstte, tam genişlik */
@media (max-width: 991px) {
    .irem-calc-summary--dock {
        position: relative;
        width: 100%;
        max-width: 720px;
        margin-left: auto;
        margin-right: auto;
        margin-bottom: clamp(20px, 4vw, 28px);
    }

    .irem-calc-main {
        margin-left: 0;
    }
}

.irem-calc-summary__intro {
    text-align: center;
    margin-bottom: clamp(14px, 2.2vw, 18px);
    padding-bottom: 4px;
}

/* Özet — seçilen ürün satırları */
.irem-calc-summary__lines-wrap {
    margin-bottom: clamp(16px, 2.5vw, 22px);
}

.irem-calc-summary__lines-heading {
    margin: 0 0 10px;
    font-size: 0.6875rem;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: rgba(61, 56, 48, 0.52);
    text-align: center;
}

.irem-calc-summary__lines {
    list-style: none;
    margin: 0;
    padding: 0;
    max-height: min(38vh, 280px);
    overflow-y: auto;
    border-radius: 14px;
    border: 1px solid rgba(180, 157, 103, 0.22);
    background: rgba(255, 255, 255, 0.55);
}

.irem-calc-line {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 8px 10px;
    align-items: start;
    padding: 11px 14px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
    font-size: 0.8125rem;
    line-height: 1.4;
}

.irem-calc-line:last-child {
    border-bottom: none;
}

.irem-calc-line__name {
    color: var(--title-color, #1a1a1a);
    font-weight: 600;
    word-break: break-word;
}

.irem-calc-line__qty {
    font-weight: 800;
    font-variant-numeric: tabular-nums;
    font-feature-settings: "tnum" 1;
    color: #8a6f42;
    white-space: nowrap;
    padding-top: 1px;
}

.irem-calc-summary__lines-empty {
    margin: 0;
    padding: 14px 12px;
    text-align: center;
    font-size: 0.8125rem;
    line-height: 1.45;
    color: rgba(61, 56, 48, 0.52);
    border-radius: 14px;
    border: 1px dashed rgba(180, 157, 103, 0.4);
    background: rgba(255, 255, 255, 0.4);
}


.irem-calc-summary__kicker {
    display: inline-block;
    margin-bottom: 8px;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: #8a6f42;
}

.irem-calc-summary__title {
    margin: 0;
    font-family: var(--title-font, "Ubuntu", sans-serif);
    font-size: clamp(1.25rem, 2.8vw, 1.5rem);
    font-weight: 700;
    letter-spacing: -0.02em;
    color: var(--title-color, #141414);
}

.irem-calc-summary__totals {
    display: grid;
    grid-template-columns: 1fr;
    gap: 14px;
}

@media (min-width: 576px) {
    .irem-calc-summary__totals {
        grid-template-columns: 1fr 1fr;
        gap: 16px;
    }
}

.irem-calc-total {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: clamp(16px, 2.5vw, 22px) clamp(14px, 2vw, 20px);
    border-radius: 16px;
    text-align: center;
    border: 1px solid rgba(0, 0, 0, 0.05);
}

.irem-calc-total--buy {
    background: linear-gradient(180deg, rgba(52, 120, 180, 0.08) 0%, rgba(52, 120, 180, 0.03) 100%);
    border-color: rgba(52, 120, 180, 0.15);
}

.irem-calc-total--sell {
    background: linear-gradient(180deg, rgba(46, 125, 50, 0.1) 0%, rgba(46, 125, 50, 0.03) 100%);
    border-color: rgba(46, 125, 50, 0.18);
}

.irem-calc-total__label {
    font-size: 0.8125rem;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: rgba(61, 56, 48, 0.72);
}

.irem-calc-total__value {
    font-size: clamp(1.5rem, 4vw, 2rem);
    font-weight: 800;
    font-variant-numeric: tabular-nums;
    font-feature-settings: "tnum" 1;
    letter-spacing: -0.03em;
    line-height: 1.15;
}

.irem-calc-total__value.buy {
    color: #1e6fad;
}

.irem-calc-total__value.sell {
    color: #2e7d32;
}

.irem-calc-summary__actions {
    display: flex;
    justify-content: center;
    margin-top: clamp(16px, 2.5vw, 22px);
}

.irem-calc-reset {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 12px 26px;
    border: none;
    border-radius: 999px;
    font-size: 0.9375rem;
    font-weight: 600;
    cursor: pointer;
    color: #fff;
    background: linear-gradient(145deg, #c45c4a 0%, #a84136 100%);
    box-shadow: 0 4px 14px rgba(168, 65, 54, 0.35);
    transition: transform 0.2s ease, box-shadow 0.2s ease, filter 0.2s ease;
}

.irem-calc-reset:hover {
    filter: brightness(1.06);
    transform: translateY(-2px);
    box-shadow: 0 8px 22px rgba(168, 65, 54, 0.42);
}

.irem-calc-reset.is-pressed {
    transform: scale(0.98);
}

.irem-calc-reset i {
    font-size: 0.95em;
}

/* Ürün kartları */
.irem-calc-products {
    align-items: stretch;
}

.irem-calc-card {
    height: 100%;
    display: flex;
    flex-direction: column;
    border-radius: 18px;
    overflow: hidden;
    background: #fff;
    border: 1px solid rgba(180, 157, 103, 0.2);
    box-shadow:
        0 2px 4px rgba(0, 0, 0, 0.03),
        0 12px 36px rgba(40, 30, 20, 0.07);
    transition: transform 0.28s ease, box-shadow 0.28s ease, border-color 0.28s ease;
}

.irem-calc-card:hover {
    transform: translateY(-4px);
    border-color: rgba(180, 157, 103, 0.38);
    box-shadow:
        0 8px 16px rgba(0, 0, 0, 0.06),
        0 22px 48px rgba(40, 30, 20, 0.12);
}

.irem-calc-card__head {
    padding: 14px 18px;
    text-align: center;
    background: linear-gradient(145deg, #c4a86a 0%, #9a7d4a 52%, #8a6f42 100%);
    border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}

.irem-calc-card__title {
    display: block;
    font-size: clamp(0.95rem, 2vw, 1.0625rem);
    font-weight: 700;
    letter-spacing: 0.02em;
    color: #fff;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.12);
}

.irem-calc-card__body {
    flex: 1;
    display: flex;
    flex-direction: column;
    padding: clamp(18px, 3vw, 22px);
    gap: 16px;
}

.irem-calc-card__visual {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 120px;
    max-height: 140px;
}

.irem-calc-card__img {
    max-height: 120px;
    width: auto;
    max-width: 100%;
    object-fit: contain;
}

.irem-calc-card__icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 72px;
    height: 72px;
    border-radius: 50%;
    font-size: 2rem;
    color: #8a6f42;
    background: linear-gradient(180deg, rgba(180, 157, 103, 0.18) 0%, rgba(180, 157, 103, 0.06) 100%);
    border: 1px solid rgba(180, 157, 103, 0.25);
}

.irem-calc-card__qty {
    text-align: center;
}

.irem-calc-card__qty-label {
    display: block;
    margin-bottom: 8px;
    font-size: 0.8125rem;
    font-weight: 600;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    color: rgba(61, 56, 48, 0.65);
}

.irem-calc-qty {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0;
    padding: 4px;
    border-radius: 999px;
    background: rgba(180, 157, 103, 0.1);
    border: 1px solid rgba(180, 157, 103, 0.22);
}

.irem-calc-qty__btn {
    width: 40px;
    height: 40px;
    border: none;
    border-radius: 999px;
    font-size: 1.25rem;
    font-weight: 700;
    line-height: 1;
    color: #fff;
    cursor: pointer;
    background: linear-gradient(145deg, #c4a86a 0%, #8a6f42 100%);
    box-shadow: 0 2px 8px rgba(138, 111, 66, 0.35);
    transition: transform 0.15s ease, filter 0.15s ease;
}

.irem-calc-qty__btn:hover {
    filter: brightness(1.08);
}

.irem-calc-qty__btn:active {
    transform: scale(0.96);
}

.irem-calc-qty__input {
    width: 72px !important;
    margin: 0 10px !important;
    padding: 8px 6px !important;
    text-align: center;
    font-weight: 700;
    font-size: 1.0625rem;
    border: none !important;
    border-radius: 12px !important;
    background: #fff !important;
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.06);
}

.irem-calc-qty__input:focus {
    outline: 2px solid rgba(138, 111, 66, 0.45);
    outline-offset: 2px;
}

.irem-calc-card__prices {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
    margin-top: auto;
}

.irem-calc-tag {
    display: inline-flex;
    align-items: baseline;
    gap: 6px;
    padding: 8px 12px;
    border-radius: 999px;
    font-size: 0.8125rem;
    font-weight: 600;
    letter-spacing: 0.02em;
}

.irem-calc-tag strong {
    font-weight: 800;
    font-variant-numeric: tabular-nums;
}

.irem-calc-tag--buy {
    color: #1565c0;
    background: rgba(21, 101, 192, 0.09);
    border: 1px solid rgba(21, 101, 192, 0.18);
}

.irem-calc-tag--sell {
    color: #2e7d32;
    background: rgba(46, 125, 50, 0.1);
    border: 1px solid rgba(46, 125, 50, 0.2);
}

/* Boş durum */
.irem-calc-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 14px;
    padding: clamp(28px, 5vw, 40px);
    text-align: center;
    border-radius: 18px;
    background: rgba(255, 243, 224, 0.85);
    border: 1px solid rgba(230, 162, 60, 0.35);
}

.irem-calc-empty__icon {
    font-size: 2rem;
    color: #c77800;
}

.irem-calc-empty__text {
    margin: 0;
    max-width: 28rem;
    font-size: 1rem;
    line-height: 1.55;
    color: #5c4a2d;
}

.quantity-input::-webkit-outer-spin-button,
.quantity-input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.quantity-input {
    -moz-appearance: textfield;
}

/* Koyu tema */
html.dark_home .irem-calc-lede {
    color: rgba(220, 215, 205, 0.88);
}

html.dark_home .irem-calc {
    background:
        radial-gradient(120% 80% at 50% -15%, rgba(200, 175, 115, 0.1) 0%, transparent 55%),
        linear-gradient(180deg, #161514 0%, #0f0e0d 100%);
}

html.dark_home .irem-calc-summary {
    background: linear-gradient(165deg, rgba(34, 32, 30, 0.96) 0%, rgba(22, 21, 19, 0.98) 100%);
    border-color: rgba(255, 255, 255, 0.1);
    box-shadow:
        0 8px 32px rgba(0, 0, 0, 0.35),
        inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

@media (min-width: 992px) {
    html.dark_home .irem-calc-summary--dock {
        border-right-color: rgba(255, 255, 255, 0.1);
        border-top: none;
        border-bottom: none;
        border-left: none;
        box-shadow: 4px 0 32px rgba(0, 0, 0, 0.45);
    }
}

html.dark_home .irem-calc-summary__lines-heading {
    color: rgba(255, 255, 255, 0.45);
}

html.dark_home .irem-calc-summary__lines {
    background: rgba(0, 0, 0, 0.22);
    border-color: rgba(255, 255, 255, 0.1);
}

html.dark_home .irem-calc-line {
    border-bottom-color: rgba(255, 255, 255, 0.07);
}

html.dark_home .irem-calc-line__name {
    color: rgba(242, 240, 236, 0.94);
}

html.dark_home .irem-calc-line__qty {
    color: #e8cc8c;
}

html.dark_home .irem-calc-summary__lines-empty {
    color: rgba(255, 255, 255, 0.48);
    border-color: rgba(255, 255, 255, 0.14);
    background: rgba(255, 255, 255, 0.04);
}

html.dark_home .irem-calc-summary__kicker {
    color: #d4b87a;
}

html.dark_home .irem-calc-summary__title {
    color: #f2f0ec;
}

html.dark_home .irem-calc-total__label {
    color: rgba(255, 255, 255, 0.62);
}

html.dark_home .irem-calc-total--buy {
    background: linear-gradient(180deg, rgba(30, 111, 173, 0.18) 0%, rgba(30, 111, 173, 0.06) 100%);
    border-color: rgba(100, 181, 246, 0.22);
}

html.dark_home .irem-calc-total--sell {
    background: linear-gradient(180deg, rgba(67, 160, 71, 0.18) 0%, rgba(67, 160, 71, 0.06) 100%);
    border-color: rgba(129, 199, 132, 0.28);
}

html.dark_home .irem-calc-total__value.buy {
    color: #90caf9;
}

html.dark_home .irem-calc-total__value.sell {
    color: #a5d6a7;
}

html.dark_home .irem-calc-card {
    background: linear-gradient(180deg, #242220 0%, #1a1816 100%);
    border-color: rgba(255, 255, 255, 0.08);
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.35);
}

html.dark_home .irem-calc-card:hover {
    border-color: rgba(212, 184, 122, 0.28);
}

html.dark_home .irem-calc-card__qty-label {
    color: rgba(255, 255, 255, 0.55);
}

html.dark_home .irem-calc-qty {
    background: rgba(255, 255, 255, 0.06);
    border-color: rgba(255, 255, 255, 0.1);
}

html.dark_home .irem-calc-qty__input {
    background: rgba(15, 14, 13, 0.9) !important;
    color: #f2f0ec !important;
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.35);
}

html.dark_home .irem-calc-tag--buy {
    color: #90caf9;
    background: rgba(100, 181, 246, 0.12);
    border-color: rgba(100, 181, 246, 0.25);
}

html.dark_home .irem-calc-tag--sell {
    color: #a5d6a7;
    background: rgba(129, 199, 132, 0.12);
    border-color: rgba(129, 199, 132, 0.28);
}

html.dark_home .irem-calc-empty {
    background: rgba(255, 193, 7, 0.08);
    border-color: rgba(255, 193, 7, 0.22);
}

html.dark_home .irem-calc-empty__text {
    color: rgba(255, 255, 255, 0.82);
}

@media (max-width: 767px) {
    .irem-calc-total__value {
        font-size: clamp(1.35rem, 5vw, 1.65rem);
    }

    .irem-calc-qty__btn {
        width: 38px;
        height: 38px;
    }

    .irem-calc-qty__input {
        width: 64px !important;
        margin: 0 8px !important;
    }
}
