/* Modern E-Ticaret / SaaS Tasarım Teması */
html,
body {
    width: 100%;
    max-width: 100%;
    overflow-x: hidden;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

body.product-page-body {
    background-color: #f8fafc;
    color: #0f172a;
    font-family: var(--font-body), sans-serif;
    margin: 0;
    padding: 0;
    width: 100%;
    max-width: 100%;
    overflow-x: hidden;
}

.product-page,
.product-grid,
.product-gallery-box,
.product-options-box,
.product-summary-box,
.product-details-tabs,
.product-left-column {
    width: 100%;
    max-width: 100%;
    min-width: 0;
}

img,
iframe {
    max-width: 100%;
}

.product-page {
    max-width: 1280px;
    margin: 0 auto;
    padding: 1.5rem 1rem 4rem 1rem;
}

/* Breadcrumb & Header */
.product-header {
    margin-bottom: 2rem;
    border-bottom: 1px solid #e2e8f0;
    padding-bottom: 1rem;
}

.breadcrumb {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.78rem;
    color: #64748b;
    margin-bottom: 0.5rem;
}

.breadcrumb a {
    color: #64748b;
    text-decoration: none;
    transition: color 0.2s;
}

.breadcrumb a:hover {
    color: #0ea5e9;
}

.product-title {
    font-family: var(--font-heading), sans-serif;
    font-size: 1.8rem;
    font-weight: 800;
    color: #0f172a;
    margin: 0 0 0.4rem 0;
    letter-spacing: -0.5px;
}

.product-rating {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.85rem;
}

.product-rating .stars {
    color: #f59e0b;
    font-weight: bold;
    letter-spacing: 1px;
}

.product-rating .count {
    color: #64748b;
    font-weight: 500;
}

/* 3 Kolon Düzeni (Desktop & Mobile Adaptasyon) */
@media (min-width: 1025px) {
    .product-grid {
        display: grid;
        grid-template-columns: minmax(280px, 330px) minmax(420px, 1fr) minmax(280px, 320px);
        gap: 24px;
        align-items: start;
    }
    .product-left-column {
        grid-column: 1;
        display: flex;
        flex-direction: column;
        gap: 16px;
        min-width: 0;
    }
    .product-options-box {
        grid-column: 2;
        min-width: 0;
    }
    .product-summary-box {
        grid-column: 3;
        position: sticky;
        top: 100px;
        min-width: 0;
    }
}

@media (max-width: 1024px) {
    .product-grid {
        display: flex;
        flex-direction: column;
        gap: 16px;
        width: 100%;
        max-width: 100%;
        min-width: 0;
    }
    .product-left-column {
        display: contents;
    }
    .product-gallery-box {
        order: 1;
        overflow: hidden;
    }
    .product-options-box {
        order: 2;
    }
    .product-summary-box {
        order: 3;
        position: static;
    }
    .helper-card-check {
        order: 4;
    }
    .helper-card-formats {
        order: 5;
    }
}

.bg-white-card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 1rem;
    padding: 1.25rem;
    box-shadow: 0 1px 3px rgba(0,0,0,0.02);
    margin-bottom: 0;
}

.aspect-video-box {
    position: relative;
    width: 100%;
    padding-bottom: 56.25%; /* 16:9 aspect ratio */
    border-radius: 0.75rem;
    overflow: hidden;
    background: #0f172a;
    max-width: 100%;
}

.aspect-video-box iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 0;
    max-width: 100%;
    display: block;
}

.aspect-video-box img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 0;
    max-width: 100%;
    display: block;
    object-fit: cover;
    background: #f8fafc;
}

.info-card-title {
    font-family: var(--font-heading), sans-serif;
    font-size: 0.85rem;
    font-weight: 700;
    color: #0f172a;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.info-card-text {
    font-size: 0.8rem;
    color: #475569;
    line-height: 1.5;
}

.info-card-list {
    margin: 0.5rem 0 0 0;
    padding-left: 1.25rem;
    font-size: 0.78rem;
    color: #475569;
    line-height: 1.6;
}

/* Media Gallery */
.gallery-thumbs {
    display: flex;
    gap: 0.5rem;
    overflow-x: auto;
    overflow-y: hidden;
    padding-bottom: 0.25rem;
    scrollbar-width: thin;
    max-width: 100%;
    width: 100%;
    -webkit-overflow-scrolling: touch;
}

.thumb-btn {
    position: relative;
    width: 70px;
    height: 50px;
    border: 2px solid #e2e8f0;
    border-radius: 0.5rem;
    overflow: hidden;
    cursor: pointer;
    flex: 0 0 70px;
    max-width: 70px;
    background: #f1f5f9;
    padding: 0;
    transition: all 0.2s ease;
}

.thumb-btn:hover, .thumb-btn.active {
    border-color: #0ea5e9;
    box-shadow: 0 2px 8px rgba(14, 165, 233, 0.15);
}

.thumb-btn img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.thumb-video-icon {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, 0.4);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1rem;
    transition: background 0.2s;
}

.thumb-btn:hover .thumb-video-icon {
    background: rgba(15, 23, 42, 0.6);
}

/* Single Options Card Layout */
.product-options-card {
    position: relative !important;
    overflow: hidden !important;
    isolation: isolate !important;
    border: none !important;
    border-radius: 1.25rem !important;
    background: transparent !important;
    box-shadow: 0 4px 20px rgba(15, 23, 42, 0.03) !important;
}

.product-options-card::before {
    content: "";
    position: absolute;
    inset: -50%;
    background: conic-gradient(
        from 0deg,
        #00aeef,
        #ec008c,
        #fff200,
        #111827,
        #00aeef
    );
    animation: cmykBorderRotate 10s linear infinite;
    z-index: 0;
    pointer-events: none;
}

.product-options-card::after {
    content: "";
    position: absolute;
    inset: 1.5px;
    background: #ffffff;
    border-radius: calc(1.25rem - 1.5px);
    z-index: 1;
    pointer-events: none;
}

.product-options-card > * {
    position: relative;
    z-index: 2;
    background: #ffffff;
}

@keyframes cmykBorderRotate {
    to {
        transform: rotate(360deg);
    }
}

@media (prefers-reduced-motion: reduce) {
    .product-options-card::before {
        animation: none;
    }
}

.qty-quick-btn.active,
.form-input:focus,
.option-card.active {
    border-color: #0ea5e9 !important;
    background: #eff6ff !important;
    color: #0369a1 !important;
    box-shadow: 0 0 0 1px #0ea5e9, 0 8px 20px rgba(14, 165, 233, 0.12) !important;
    outline: none !important;
}

.qty-quick-btn.active {
    font-weight: 800 !important;
}

.form-input:focus {
    outline: none !important;
}

.option-section {
    padding: 1.5rem;
    border-bottom: 1px solid #e2e8f0;
}

.option-section:last-child {
    border-bottom: none;
}

.option-label {
    display: block;
    font-size: 0.78rem;
    font-weight: 800;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0.75rem;
}

.options-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
    gap: 0.75rem;
}

.option-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 1rem 0.75rem;
    border: 1.5px solid #e2e8f0;
    border-radius: 0.75rem;
    background: white;
    color: #0f172a;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: center;
    font-family: inherit;
    width: 100%;
}

.option-card i {
    font-size: 1.25rem;
    margin-bottom: 0.4rem;
    color: #64748b;
}

.option-card:hover {
    border-color: #0ea5e9;
    box-shadow: 0 4px 12px rgba(14, 165, 233, 0.08);
}

.option-card.active {
    border-color: #0ea5e9;
    background: #eff6ff;
    color: #0369a1;
    box-shadow: 0 0 0 1px #0ea5e9;
}

.option-card.active i {
    color: #0ea5e9;
}

/* Adet Listesi */
.quantity-list {
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
    margin-top: 0.25rem;
}

.quantity-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.9rem 1.25rem;
    border: 1.5px solid #e2e8f0;
    border-radius: 0.75rem;
    background: white;
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: left;
    width: 100%;
    box-sizing: border-box;
    font-family: inherit;
}

.quantity-row:hover {
    border-color: #0ea5e9;
    box-shadow: 0 4px 12px rgba(14, 165, 233, 0.08);
}

.quantity-row.active {
    border-color: #0ea5e9;
    background: #eff6ff;
    box-shadow: 0 0 0 1px #0ea5e9;
}

.quantity-row .qty-info {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    line-height: 1.2;
}

.quantity-row .qty-info strong {
    font-size: 1.15rem;
    font-weight: 800;
    color: #0f172a;
}

.quantity-row.active .qty-info strong {
    color: #0369a1;
}

.quantity-row .qty-info small {
    font-size: 0.72rem;
    color: #64748b;
    font-weight: 600;
    margin-top: 2px;
}

.quantity-row.active .qty-info small {
    color: #0ea5e9;
}

.quantity-row .price-info {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    line-height: 1.2;
}

.quantity-row .price-info .amount {
    font-weight: 800;
    font-size: 1.15rem;
    color: #0f172a;
}

.quantity-row.active .price-info .amount {
    color: #0369a1;
}

.quantity-row .price-info .tax-lbl {
    font-size: 0.7rem;
    color: #64748b;
    font-weight: 600;
    margin-top: 2px;
}

.quantity-row.active .price-info .tax-lbl {
    color: #0ea5e9;
}

/* Sağ Alan: Summary (Sticky) */
.summary-card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 1.25rem;
    padding: 1.5rem;
    box-shadow: 0 4px 20px rgba(15, 23, 42, 0.03);
}

.summary-title {
    font-size: 0.8rem;
    font-weight: 800;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    display: block;
    margin-bottom: 0.25rem;
}

.summary-price {
    font-size: 2.2rem;
    font-weight: 800;
    color: #0ea5e9;
    letter-spacing: -1px;
    line-height: 1;
}

.summary-tax {
    font-size: 0.75rem;
    color: #64748b;
    margin-top: 0.35rem;
    font-weight: 500;
}

.summary-specs {
    margin: 1.25rem 0;
    border-top: 1px solid #e2e8f0;
    border-bottom: 1px solid #e2e8f0;
    padding: 0.75rem 0;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.spec-row {
    display: flex;
    justify-content: space-between;
    font-size: 0.8rem;
    line-height: 1.4;
}

.spec-row .lbl {
    color: #64748b;
    font-weight: 500;
}

.spec-row .val {
    color: #0f172a;
    font-weight: 700;
    text-align: right;
    max-width: 180px;
}

.action-btn {
    width: 100%;
    border-radius: 0.75rem;
    padding: 0.85rem;
    font-size: 0.95rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    font-family: inherit;
}

.primary-btn {
    background: #0ea5e9;
    color: white;
    border: none;
    box-shadow: 0 4px 14px rgba(14, 165, 233, 0.3);
    margin-bottom: 0.75rem;
}

.primary-btn:hover {
    background: #0284c7;
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(14, 165, 233, 0.4);
}

.secondary-btn {
    background: white;
    color: #0ea5e9;
    border: 1.5px solid #0ea5e9;
}

.secondary-btn:hover {
    background: #eff6ff;
    transform: translateY(-1px);
}

.cargo-estimation {
    margin-top: 1.25rem;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 0.75rem;
    padding: 0.75rem;
    font-size: 0.75rem;
    color: #475569;
    line-height: 1.4;
}

.cargo-estimation i {
    color: #0ea5e9;
    margin-right: 0.25rem;
}

.trust-icons {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.5rem;
    margin-top: 1.25rem;
    padding-top: 1rem;
    border-top: 1px dashed #e2e8f0;
}

.trust-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    font-size: 0.65rem;
    color: #64748b;
    font-weight: 600;
    gap: 0.25rem;
}

.trust-item i {
    font-size: 1rem;
    color: #0ea5e9;
}

/* Bottom Details Tab Panel */
.product-details-tabs {
    margin-top: 3rem;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 1.25rem;
    padding: 2rem;
    box-shadow: 0 1px 3px rgba(0,0,0,0.02);
    width: 100%;
    max-width: 100%;
    min-width: 0;
}

.tabs-header {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0.5rem;
    border-bottom: none;
    margin-bottom: 1.5rem;
    overflow: visible;
    background: #f8fafc;
    padding: 0.4rem;
    border-radius: 0.9rem;
}

.tab-btn {
    background: none;
    border: none;
    padding: 0.75rem 0.5rem;
    font-family: inherit;
    font-size: 0.95rem;
    font-weight: 700;
    color: #64748b;
    cursor: pointer;
    position: relative;
    transition: all 0.2s;
    width: 100%;
    min-width: 0;
    white-space: normal;
    text-align: center;
    border-radius: 0.65rem;
}

.tab-btn:hover {
    color: #0ea5e9;
}

.tab-btn.active {
    background: #0ea5e9;
    color: white;
}

.tab-btn.active::after {
    display: none;
}

@media (max-width: 768px) {
    .tabs-header {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 0.5rem;
    }

    .tab-btn {
        font-size: 0.8rem;
        padding: 0.7rem 0.4rem;
    }

    .product-details-tabs {
        padding: 1rem;
    }
}

.tab-content-panel {
    display: none;
    animation: fadeIn 0.3s ease-in-out;
}

.tab-content-panel.active {
    display: block;
}

.tab-content-panel h3 {
    font-family: var(--font-heading), sans-serif;
    font-size: 1.25rem;
    font-weight: 800;
    color: #0f172a;
    margin: 0 0 1rem 0;
}

.tab-content-panel p {
    font-size: 0.88rem;
    color: #475569;
    line-height: 1.7;
    margin: 0 0 1rem 0;
}

/* FAQ inside tab styles */
.faq-item {
    margin-bottom: 1.5rem;
    border-bottom: 1px dashed #f1f5f9;
    padding-bottom: 1.5rem;
}

.faq-item:last-child {
    margin-bottom: 0;
    border-bottom: none;
    padding-bottom: 0;
}

.faq-question {
    font-size: 0.95rem;
    font-weight: 700;
    color: #0f172a;
    margin: 0 0 0.5rem 0;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.faq-question i {
    color: #0ea5e9;
}

.faq-answer {
    font-size: 0.85rem;
    color: #475569;
    line-height: 1.6;
    padding-left: 1.5rem;
    margin: 0;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(4px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Custom UX & Modal Styles */
.hidden {
    display: none !important;
}

.option-helper-text {
    font-size: 0.78rem;
    color: #64748b;
    line-height: 1.5;
    margin: -0.25rem 0 0.85rem 0;
}

.option-card small {
    display: block;
    margin-top: 0.25rem;
    font-size: 0.72rem;
    color: #64748b;
    font-weight: 500;
}

.option-card.active small {
    color: #0369a1;
}

.selected-product-note {
    background: #f0f9ff;
    border: 1px solid #bae6fd;
    border-radius: 0.75rem;
    padding: 1rem;
    margin-top: 1rem;
}

.selected-product-note .info-card-title {
    font-size: 0.85rem;
    font-weight: 700;
    color: #0369a1;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.35rem;
}

.selected-product-note .info-card-text {
    font-size: 0.78rem;
    color: #334155;
    line-height: 1.5;
}

#admin-auth-modal,
#admin-panel-modal {
    display: none !important;
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    width: 100vw !important;
    height: 100vh !important;
    background-color: rgba(15, 23, 42, 0.75) !important;
    backdrop-filter: blur(4px) !important;
    -webkit-backdrop-filter: blur(4px) !important;
    z-index: 100000 !important;
    align-items: center !important;
    justify-content: center !important;
    box-sizing: border-box !important;
}

#admin-auth-modal.active,
#admin-panel-modal.active {
    display: flex !important;
}

.admin-modal-box {
    background: #ffffff !important;
    border-radius: 1.5rem !important;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25) !important;
    padding: 2rem !important;
    width: 100% !important;
    position: relative !important;
    box-sizing: border-box !important;
    transition: transform 0.2s ease, opacity 0.2s ease !important;
}

#admin-auth-modal-content {
    max-width: 380px !important;
}

#admin-panel-content {
    max-width: 850px !important;
    max-height: 90vh !important;
    overflow-y: auto !important;
}

.admin-close-btn {
    position: absolute !important;
    top: 1.25rem !important;
    right: 1.25rem !important;
    background: none !important;
    border: none !important;
    color: #94a3b8 !important;
    cursor: pointer !important;
    font-size: 1.25rem !important;
    padding: 0.25rem !important;
    transition: color 0.2s !important;
}

.admin-close-btn:hover {
    color: #475569 !important;
}

.admin-tab-active {
    background-color: #eff6ff !important;
    color: #0369a1 !important;
    border: 2px solid #b9d6fe !important;
    padding: 0.5rem 1rem !important;
    border-radius: 0.5rem !important;
    cursor: pointer !important;
    font-weight: 700 !important;
}

.admin-tab-inactive {
    background-color: #f1f5f9 !important;
    color: #475569 !important;
    border: 2px solid transparent !important;
    padding: 0.5rem 1rem !important;
    border-radius: 0.5rem !important;
    cursor: pointer !important;
    font-weight: 700 !important;
    transition: background-color 0.2s !important;
}

.admin-tab-inactive:hover {
    background-color: #e2e8f0 !important;
}
