/* =========================================
   Cookd AI Labs Section - Polished Light Theme
   ========================================= */

.ai-labs-section {
    background-color: var(--section-bg2);
    /* Light warm background from main theme */
    position: relative;
    z-index: 1;
}

/* Header Styles */


.ai-labs-header h3 {
    color: var(--black);
}

.ai-labs-subtitle {
    color: var(--text-secondary);
    /* Standard text styling */
}

/* Card Styles */
.ai-labs-card {
    background: #ffffff;
    border: 1px solid rgba(0, 0, 0, 0.05) !important;
    border-radius: 16px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.03);
    transition: all 0.4s cubic-bezier(0.2, 0.8, 0.2, 1);
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.ai-labs-card::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, #f25824 0%, #FBBC00 100%);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.ai-labs-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(242, 88, 36, 0.08);
    /* Subtle colored shadow */
    border-color: rgba(242, 88, 36, 0.1) !important;
}

.ai-labs-card:hover::before {
    opacity: 1;
}

/* Typography in Cards */
.ai-labs-card h4 a {
    color: var(--black);
    transition: color 0.3s ease;
}

.ai-labs-card:hover h4 a {
    color: var(--theme);
}

.ai-labs-card .text-secondary {
    color: #666 !important;
}

/* Icon Styles - Modern Light Wrapper */
.ai-labs-icon {
    width: 70px;
    height: 70px;
    background: rgba(242, 88, 36, 0.06);
    color: var(--theme);
    font-size: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.4s ease;
    margin-bottom: 20px;
}

.ai-labs-card:hover .ai-labs-icon {
    background: var(--theme);
    color: #ffffff;
    transform: scale(1.05) rotate(-5deg);
    box-shadow: 0 10px 20px rgba(242, 88, 36, 0.2);
}

/* Button Styling in Cards */
.ai-labs-card .theme-btn.btn-outline-theme {
    border-color: rgba(242, 88, 36, 0.2);
    color: var(--theme);
    background: transparent;
    padding: 12px 24px;
}

.ai-labs-card .theme-btn.btn-outline-theme:hover {
    background: var(--theme);
    border-color: var(--theme);
    color: #ffffff;
}

/* CTA Button at Top */
.ai-labs-cta {
    position: relative;
    z-index: 2;
    background: #fff;
    border-color: #eee;
}

.ai-labs-cta:hover {
    background: var(--black);
    color: #fff !important;
    border-color: var(--black);
}

/* =========================================
   AI Cooking Coach Page specific styles
   ========================================= */

/* Side Cards (Settings & Quick Start) */
.ai-coach-sidecard {
    background: #fff;
    border: 1px solid rgba(0, 0, 0, 0.06) !important;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.02);
    border-radius: 16px;
    transition: transform 0.3s ease;
}

.ai-coach-sidecard:hover {
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
}

/* Recipe Cards in Grid */
.ai-coach-recipe-card {
    display: block;
    background: #fff;
    border: 1px solid rgba(0, 0, 0, 0.06);
    border-radius: 16px;
    padding: 24px;
    transition: all 0.3s cubic-bezier(0.2, 0.8, 0.2, 1);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.02);
    /* Slight shadow to fix alignment by defining edge */
    height: 100%;
}

.ai-coach-recipe-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(242, 88, 36, 0.1);
    border-color: rgba(242, 88, 36, 0.3);
}

.ai-coach-recipe-icon {
    width: 50px;
    height: 50px;
    background: rgba(242, 88, 36, 0.08);
    /* Light orange tint */
    color: var(--theme);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    transition: all 0.3s ease;
}

.ai-coach-recipe-card:hover .ai-coach-recipe-icon {
    background: var(--theme);
    color: #fff;
    transform: rotate(-10deg) scale(1.1);
}

/* Level Selection Buttons */
.ai-coach-level .theme-btn {
    border-color: rgba(0, 0, 0, 0.1);
    color: var(--black);
    background: #fff;
    min-width: 100px;
}

.ai-coach-level .theme-btn.is-active {
    background: var(--theme);
    color: #fff;
    border-color: var(--theme);
}

.ai-coach-level .theme-btn:hover {
    border-color: var(--theme);
    color: var(--theme);
}

.ai-coach-level .theme-btn.is-active:hover {
    color: #fff;
}

/* Feature/Tip box */
.ai-coach-tip {
    background: rgba(242, 88, 36, 0.04) !important;
    border: 1px dashed rgba(242, 88, 36, 0.2) !important;
}

.ai-coach-tip .theme-clr {
    -webkit-text-fill-color: initial;
    color: var(--theme);
}

/* =========================================
   AI Coach Mode - White Theme Overlay
   ========================================= */

/* Floating Animations */
@keyframes coachFloat1 {
    0% {
        transform: translate(0, 0) rotate(0deg);
    }

    50% {
        transform: translate(30px, 20px) rotate(5deg);
    }

    100% {
        transform: translate(0, 0) rotate(0deg);
    }
}

@keyframes coachFloat2 {
    0% {
        transform: translate(0, 0) scale(1);
    }

    50% {
        transform: translate(-20px, -20px) scale(1.1);
    }

    100% {
        transform: translate(0, 0) scale(1);
    }
}

.ai-coach-mode {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at center, #ffffff 0%, #fff9f5 100%);
    z-index: 9999;
    overflow-y: auto;
    padding-top: 80px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.ai-coach-mode::before {
    content: "";
    position: fixed;
    top: 10%;
    left: 0;
    width: 35vw;
    height: 35vw;
    max-width: 400px;
    max-height: 400px;
    background-image: url('../img/inner-global-oblet.png'), radial-gradient(circle at center, rgba(251, 188, 0, 0.15) 0%, transparent 70%);
    background-size: contain, 120% 120%;
    background-position: center bottom, center center;
    background-repeat: no-repeat;
    z-index: 0;
    pointer-events: none;
    transform: translateX(-30%);
    opacity: 0.5;
}

.ai-coach-mode::after {
    content: "";
    position: fixed;
    bottom: -5%;
    left: -5%;
    right: auto;
    width: 40vw;
    height: 40vw;
    max-width: 500px;
    max-height: 500px;
    background-image: url('../img/inner-global-pasta.png'), radial-gradient(circle at center, rgba(242, 88, 36, 0.1) 0%, transparent 70%);
    background-size: contain, 120% 120%;
    background-position: center top, center center;
    background-repeat: no-repeat;
    opacity: 0.5;
    z-index: 0;
    pointer-events: none;
}

/* Top Navigation Bar */
.ai-coach-topbar {
    width: 100%;
    position: fixed;
    top: 0;
    left: 0;
    z-index: 100;
    border-bottom: 1px solid rgba(0, 0, 0, 0.08);
}

.ai-coach-topbar .theme-btn {
    font-size: 14px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.ai-coach-topbar .theme-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.ai-coach-recipe {
    font-weight: 700;
    font-size: 18px;
    text-align: center;
    color: var(--black);
}

.ai-coach-stepmeta {
    font-size: 14px;
    text-align: center;
    color: #666;
}

/* Progress Bar */
.ai-coach-progress {
    width: 100%;
}

.ai-coach-progress .progress {
    background: rgba(0, 0, 0, 0.05);
}

.ai-coach-progress .progress-bar {
    transition: width 0.3s ease;
}

/* Main Stage Area */
.ai-coach-stage {
    width: 100%;
    flex-grow: 1;
    display: flex;
    justify-content: center;
    padding: 20px;
    position: relative;
    z-index: 5;
}

.ai-coach-stage-inner {
    width: 100%;
    max-width: 800px;
}

/* Main Card Content */
.ai-coach-card {
    text-align: center;
    margin-bottom: 18px;
}

.ai-coach-stepnumber {
    display: inline-block;
}

.ai-coach-instruction {
    font-size: 36px;
    font-weight: 700;
    line-height: 1.3;
    color: var(--black);
}

.ai-coach-detail {
    font-size: 18px;
    color: #555;
    line-height: 1.6;
}

/* AI Assistant Bubble */
.ai-coach-assistant {
    text-align: left;
}

.ai-coach-bot {
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Interactive Cue */
.ai-coach-cue {
    text-align: left;
}

.ai-coach-cue-icon {
    display: flex;
    align-items: center;
    justify-content: center;
}

.ai-coach-cue .theme-btn {
    font-size: 15px;
    font-weight: 600;
}

/* Navigation Controls */
.ai-coach-controls {
    text-align: center;
}

.ai-coach-controls .theme-btn {
    font-weight: 600;
    transition: all 0.3s ease;
}

.ai-coach-controls .theme-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.12);
}

/* Help Box */
.ai-coach-help {
    text-align: left;
}

/* Completion Screen */
.ai-coach-finish {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 400px;
}

.ai-coach-finish-card {
    animation: fadeInUp 0.5s ease;
}

.ai-coach-finish-badge {
    display: flex;
    align-items: center;
    justify-content: center;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Timer Overlay */
.ai-coach-timer {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.ai-coach-timer-card {
    width: 100%;
    max-width: 400px;
    animation: scaleIn 0.3s ease;
}

@keyframes scaleIn {
    from {
        opacity: 0;
        transform: scale(0.9);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}

.ai-coach-timer-display {
    font-family: 'Courier New', monospace;
    letter-spacing: 4px;
}

/* Decorative Big Text */
.ai-coach-bg-text {
    position: fixed;
    right: 0;
    top: 50%;
    transform: translateY(-50%) rotate(180deg);
    writing-mode: vertical-rl;
    text-orientation: mixed;
    font-size: 25vh;
    font-weight: 900;
    line-height: 0.8;
    color: var(--theme);
    opacity: 0.02;
    z-index: 0;
    pointer-events: none;
    text-transform: uppercase;
    font-family: inherit;
    white-space: nowrap;
    letter-spacing: 1px;
    user-select: none;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .ai-coach-mode {
        padding-top: 70px;
    }

    .ai-coach-instruction {
        font-size: 28px;
    }

    .ai-coach-detail {
        font-size: 16px;
    }

    .ai-coach-topbar .d-sm-inline {
        display: none !important;
    }

    .ai-coach-timer-display {
        font-size: 48px !important;
    }
}

@media (max-width: 576px) {
    .ai-coach-instruction {
        font-size: 24px;
    }

    .ai-coach-detail {
        font-size: 15px;
    }

    .ai-coach-bg-text {
        font-size: 15vh;
    }
}