/* ============================================================
   PČELINJI DAROVI ŽIVKOVIĆ - ZANIMLJIVOSTI.CSS
   Master Academic/Scientific Design System
   ============================================================ */

:root {
    --honey: #d97706;
    --honey-light: #fbbf24;
    --honey-dark: #b45309;
    --dark-wood: #1a0f0a;
    --cream: #fdfcf8;
    --cream-deep: #f9f5eb;
    --text-muted: #5b5753;
    --success-green: #15803d;
    --error-red: #b91c1c;
    --font-editorial: 'Playfair Display', Georgia, serif;
    --font-precise: 'Source Sans 3', -apple-system, sans-serif;
    --transition-premium: all 0.5s cubic-bezier(0.2, 1, 0.3, 1);
    --shadow-premium: 0 20px 40px rgba(26, 15, 10, 0.05);
}

body {
    background-color: var(--cream);
    color: var(--dark-wood);
}

/* ------------------------------------------------------------
   2. HERO SECTION (EDITORIAL INTRO)
   ------------------------------------------------------------ */

.story-hero {
    position: relative;
    padding: 200px 0 140px;
    background: linear-gradient(rgba(26,15,10,0.7), rgba(26,15,10,0.95)), 
                url('images/pcelinjak.jpg') center/cover no-repeat;
    background-attachment: fixed;
    color: white;
    text-align: center;
    border-bottom: 4px solid var(--honey);
}

.hero-badge-minimal {
    text-transform: uppercase;
    letter-spacing: 2px;
    font-size: 0.8rem;
    color: var(--honey);
    border-bottom: 1px solid var(--honey);
    padding-bottom: 4px;
    display: inline-block;
    margin-bottom: 25px;
    font-weight: 600;
}

.story-hero h1 {
    font-family: var(--font-editorial);
    font-size: clamp(2.5rem, 6vw, 4.5rem);
    line-height: 1.1;
    margin-bottom: 20px;
}

.story-hero p {
    font-family: var(--font-precise);
    font-size: 1.25rem;
    max-width: 750px;
    margin: 0 auto;
    opacity: 0.9;
    font-weight: 300;
    line-height: 1.6;
}

/* ------------------------------------------------------------
   3. TAB SYSTEM (SOCIAL STRATIFICATION)
   ------------------------------------------------------------ */

.tabs-nav {
    display: flex;
    justify-content: center;
    gap: 40px;
    border-bottom: 1px solid rgba(35,18,11,0.08);
    margin-bottom: 60px;
}

.tab-btn {
    background: none;
    border: none;
    padding: 15px 5px;
    font-family: var(--font-precise);
    font-weight: 600;
    color: var(--text-muted);
    cursor: pointer;
    transition: var(--transition-premium);
    position: relative;
    font-size: 1.1rem;
}

.tab-btn::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--honey);
    transition: var(--transition-premium);
}

.tab-btn:hover {
    color: var(--dark-wood);
}

.tab-btn.active {
    color: var(--dark-wood);
}

.tab-btn.active::after {
    width: 100%;
}

.tab-panel {
    display: none;
    opacity: 0;
    transform: translateY(10px);
    transition: opacity 0.5s ease, transform 0.5s ease;
}

.tab-panel.active {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 80px;
    align-items: center;
    opacity: 1;
    transform: translateY(0);
}

.panel-text h3 {
    font-family: var(--font-editorial);
    font-size: 2.2rem;
    color: var(--dark-wood);
    margin-bottom: 25px;
}

.panel-text p {
    font-size: 1.1rem;
    line-height: 1.7;
    color: var(--text-muted);
}

.panel-image {
    position: relative;
    width: 100%;
}

.panel-img-content {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: var(--transition-premium);
}

.panel-image img {
    border-radius: 20px;
    box-shadow: 0 40px 80px rgba(26, 15, 10, 0.12);
    border: 1px solid rgba(217, 119, 6, 0.1);
}

.panel-image:hover img {
    transform: scale(1.02);
}

/* ------------------------------------------------------------
   4. FLIP CARDS (BIOCHEMICAL SUPERPOWERS)
   ------------------------------------------------------------ */

.flip-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 30px;
    perspective: 2000px;
}

.flip-card {
    height: 380px;
    perspective: 1500px;
    cursor: pointer;
}

.flip-inner {
    position: relative;
    width: 100%;
    height: 100%;
    text-align: center;
    transition: transform 0.8s cubic-bezier(0.34, 1.56, 0.64, 1);
    transform-style: preserve-3d;
}

.flip-card:hover .flip-inner {
    transform: rotateY(180deg);
}

.flip-front, .flip-back {
    backface-visibility: hidden;
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    padding: 50px 40px;
    border-radius: 24px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.flip-front {
    background: white;
    border: 1px solid rgba(26, 15, 10, 0.04);
    box-shadow: var(--shadow-premium);
}

.flip-front h3 {
    font-family: var(--font-editorial);
    font-size: 1.8rem;
    color: var(--dark-wood);
    margin: 20px 0 10px;
}

.flip-front p {
    color: var(--honey);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-size: 0.85rem;
}

.pulse-icon {
    background: rgba(217, 119, 6, 0.05);
    width: 100px;
    height: 100px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    margin-bottom: 20px;
    animation: iconPulse 3s infinite ease-in-out;
}

@keyframes iconPulse {
    0% { transform: scale(1); box-shadow: 0 0 0 0 rgba(217, 119, 6, 0.1); }
    50% { transform: scale(1.05); box-shadow: 0 0 0 20px rgba(217, 119, 6, 0); }
    100% { transform: scale(1); box-shadow: 0 0 0 0 rgba(217, 119, 6, 0); }
}

.flip-back {
    background: var(--dark-wood);
    color: white;
    transform: rotateY(180deg);
    text-align: left;
    align-items: flex-start;
}

.flip-back h4 {
    font-family: var(--font-editorial);
    font-size: 1.5rem;
    margin-bottom: 20px;
    color: var(--honey);
}

.flip-back p {
    font-size: 1rem;
    line-height: 1.6;
    opacity: 0.9;
    margin-bottom: 15px;
}

/* ------------------------------------------------------------
   5. LIQUID TIMELINE (ENZYMATIC CONVERSION)
   ------------------------------------------------------------ */

.timeline-flow {
    position: relative;
    max-width: 1000px;
    margin: 0 auto;
}

.timeline-flow::before {
    content: '';
    position: absolute;
    left: 50%;
    top: 0;
    bottom: 0;
    width: 2px;
    background: linear-gradient(to bottom, var(--honey) 50%, transparent 50%);
    background-size: 2px 12px;
    transform: translateX(-50%);
}

.step-block {
    position: relative;
    width: 50%;
    padding: 30px 60px;
    margin-bottom: 40px;
}

.step-block.left { left: 0; text-align: right; }
.step-block.right { left: 50%; text-align: left; }

.step-pointer {
    position: absolute;
    top: 50%;
    width: 20px;
    height: 20px;
    background: white;
    border: 4px solid var(--honey);
    border-radius: 50%;
    z-index: 2;
    transform: translateY(-50%);
    box-shadow: 0 0 15px rgba(217, 119, 6, 0.3);
}

.step-block.left .step-pointer { right: -8px; }
.step-block.right .step-pointer { left: -8px; }

.step-content {
    background: white;
    padding: 45px;
    border-radius: 24px;
    box-shadow: var(--shadow-premium);
    transition: var(--transition-premium);
    border: 1px solid rgba(217, 119, 6, 0.05);
}

.step-content:hover {
    transform: translateY(-8px);
    box-shadow: 0 25px 50px rgba(35, 18, 11, 0.06);
}

.step-num {
    font-family: var(--font-precise);
    font-size: 0.9rem;
    font-weight: 800;
    color: var(--honey);
    opacity: 0.5;
    display: block;
    margin-bottom: 10px;
}

.step-content h3 {
    font-family: var(--font-editorial);
    font-size: 1.6rem;
    margin-bottom: 15px;
    color: var(--dark-wood);
}

.step-content p {
    font-size: 1rem;
    line-height: 1.6;
    color: var(--text-muted);
}

/* ------------------------------------------------------------
   6. LABORATORY COMPARISON SECTION
   ------------------------------------------------------------ */

.comparison-section {
    position: relative;
    padding: 120px 0;
    background-color: var(--cream);
    overflow: hidden;
}

/* Subtle scientific grid background */
.comparison-section::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image: 
        radial-gradient(circle at 2px 2px, rgba(217, 119, 6, 0.03) 1px, transparent 0);
    background-size: 40px 40px;
    z-index: 0;
}

.comp-table-wrapper {
    position: relative;
    overflow: hidden;
    border-radius: 32px;
}

.lab-scanner {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(to bottom, transparent, var(--color-amber), transparent);
    z-index: 10;
    opacity: 0;
    pointer-events: none;
    box-shadow: 0 0 15px var(--color-amber);
}

.lab-scanner.scanning {
    animation: scanLine 2.5s ease-in-out forwards;
}

@keyframes scanLine {
    0% { top: -5%; opacity: 0.8; }
    100% { top: 105%; opacity: 0; }
}

.lab-switcher-container {
    display: none;
    background: rgba(26, 15, 10, 0.05);
    padding: 6px;
    border-radius: 16px;
    margin-bottom: 30px;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    border: 1px solid rgba(0,0,0,0.05);
    max-width: 500px;
    margin-left: auto;
    margin-right: auto;
}

.lab-toggle-btn {
    padding: 14px;
    border: none;
    background: transparent;
    border-radius: 12px;
    font-family: var(--font-body);
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--text-muted);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.lab-toggle-btn.active {
    background: white;
    color: var(--color-primary);
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
}

.lab-toggle-btn i {
    width: 20px;
    height: 20px;
}

.comp-table {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    max-width: 1200px;
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

.comp-card {
    background: rgba(255, 255, 255, 0.6);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    padding: 60px 45px;
    border-radius: 32px;
    box-shadow: 
        0 10px 30px rgba(0, 0, 0, 0.02),
        inset 0 0 0 1px rgba(255, 255, 255, 0.5);
    position: relative;
    transition: var(--transition-premium);
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.comp-card.active {
    display: flex !important;
}

.comp-card::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        90deg,
        transparent,
        rgba(255, 255, 255, 0.2),
        transparent
    );
    transition: 0.8s;
}

.comp-card:hover::after {
    left: 100%;
}

.comp-card:hover {
    transform: translateY(-12px) scale(1.01);
    box-shadow: 0 40px 80px rgba(26, 15, 10, 0.08);
    background: rgba(255, 255, 255, 0.8);
}

.comp-card.true {
    border-top: 8px solid var(--success-green);
}

.comp-card.fake {
    border-top: 8px solid var(--error-red);
}

.card-badge {
    position: absolute;
    top: 25px;
    right: 25px;
    padding: 8px 16px;
    border-radius: 50px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    display: flex;
    align-items: center;
    gap: 8px;
    z-index: 2;
}

.card-badge i {
    width: 14px;
    height: 14px;
}

.card-badge.success {
    background: rgba(21, 128, 61, 0.1);
    color: var(--success-green);
}

.card-badge.error {
    background: rgba(185, 28, 28, 0.1);
    color: var(--error-red);
}

.card-header {
    margin-bottom: 40px;
    display: flex;
    align-items: center;
    gap: 20px;
    position: relative;
    z-index: 1;
}

.header-icon {
    width: 60px;
    height: 60px;
    padding: 14px;
    background: white;
    border-radius: 20px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.06);
    color: var(--honey);
    display: flex;
    align-items: center;
    justify-content: center;
}

.card-header h3 {
    font-family: var(--font-editorial);
    font-size: 2.2rem;
    margin: 0;
    color: var(--dark-wood);
}

.comp-item {
    display: flex;
    gap: 20px;
    margin-bottom: 30px;
    padding-bottom: 25px;
    border-bottom: 1px solid rgba(0,0,0,0.04);
    position: relative;
    z-index: 1;
}

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

.item-icon {
    flex-shrink: 0;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: white;
    border-radius: 12px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.04);
    color: var(--honey);
}

.item-icon i {
    width: 20px;
    height: 20px;
}

.item-text strong {
    display: block;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--honey);
    margin-bottom: 6px;
    font-weight: 700;
}

.item-text p {
    font-size: 1.05rem;
    line-height: 1.6;
    color: var(--text-muted);
    margin: 0;
}

/* Glass effect for items on hover */
.comp-card:hover .comp-item {
    border-color: rgba(0,0,0,0.08);
}

/* ------------------------------------------------------------
   7. STRATEGIC CONCLUSION (ENCYCLOPEDIA CTA)
   ------------------------------------------------------------ */

.strategic-conclusion h2 {
    font-weight: 400;
    line-height: 1.2;
}

.btn-editorial-primary {
    display: inline-block;
    background: var(--honey);
    color: white;
    padding: 20px 50px;
    font-family: var(--font-precise);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 2px;
    border-radius: 50px;
    text-decoration: none;
    transition: var(--transition-premium);
    box-shadow: 0 15px 30px rgba(217, 119, 6, 0.2);
}

.btn-editorial-primary:hover {
    transform: scale(1.05) translateY(-3px);
    background: white;
    color: var(--dark-wood);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

/* ------------------------------------------------------------
   8. RESPONSIVENESS
   ------------------------------------------------------------ */

@media (max-width: 1024px) {
    .tab-panel.active {
        gap: 40px;
    }
}

@media (max-width: 768px) {
    .story-hero { padding: 120px 0 80px; }
    
    .tab-panel.active {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .panel-image { order: -1; }
    
    .timeline-flow::before { left: 20px; }
    
    .step-block {
        width: 100%;
        padding: 20px 20px 20px 60px;
        text-align: left !important;
    }
    
    .step-block.right { left: 0; }
    
    .step-pointer { left: 12px !important; }
    
    .comp-table {
        grid-template-columns: 1fr;
    }
    
    .strategic-conclusion h2 {
        font-size: 2.5rem;
    }
    
    .tabs-nav {
        gap: 20px;
        overflow-x: auto;
        justify-content: flex-start;
        padding-bottom: 10px;
    }
}

@media (max-width: 768px) {
    /* Lab Switcher & Comparison Adjustments */
    .lab-switcher-container {
        display: grid;
    }

    .comp-table {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .comp-card {
        display: none;
        padding: 30px 20px;
        border-radius: 20px;
    }

    .comp-card h3 {
        font-size: 1.4rem;
    }

    .comp-item {
        gap: 15px;
        padding-bottom: 20px;
        margin-bottom: 20px;
    }

    .item-icon {
        width: 24px;
        height: 24px;
    }

    .item-text strong {
        font-size: 1rem;
    }

    .item-text p {
        font-size: 0.85rem;
    }

    .card-badge {
        font-size: 0.65rem;
        padding: 4px 10px;
        top: 15px;
        right: 15px;
    }
}

@media (max-width: 480px) {
    .flip-card { 
        height: 320px; 
    }
    
    .flip-front, .flip-back {
        padding: 30px 25px;
    }

    .flip-front h3 {
        font-size: 1.5rem;
    }

    .pulse-icon {
        width: 70px;
        height: 70px;
        margin-bottom: 15px;
    }

    .pulse-icon i {
        width: 32px !important;
        height: 32px !important;
    }

    .flip-back h4 {
        font-size: 1.2rem;
        margin-bottom: 10px;
    }

    .flip-back p {
        font-size: 0.9rem;
        margin-bottom: 10px;
    }

    .step-content { padding: 25px; }
}
