/* ===================================
   BEER GARDEN THEME - Bavarian Biergarten
   =================================== */

/* Import Fonts */
@import url('https://fonts.googleapis.com/css2?family=Baloo+2:wght@400;700;800&family=Righteous&family=Nunito:wght@400;600;800&display=swap');

/* Reset & Base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --honey: #FFAE42;
    --caramel: #D4A574;
    --amber-gold: #F4A460;
    --wood-light: #DEB887;
    --wood-dark: #8B7355;
    --moss-green: #556B2F;
    --cream: #FFF8E7;
    --warm-white: #FFFEF9;

    /* Error messages - warm brown tones */
    --error-bg: rgba(139, 69, 19, 0.15);
    --error-text: #8B4513;
    --error-border: rgba(139, 69, 19, 0.3);
    --error-shadow: rgba(139, 69, 19, 0.1);

    /* Back links - wood dark on cream */
    --back-link-bg: rgba(93, 78, 55, 0.8);
    --back-link-text: #FFF8E7;
    --back-link-border: rgba(212, 165, 116, 0.4);
    --back-link-hover-bg: rgba(93, 78, 55, 0.95);
    --back-link-hover-border: rgba(212, 165, 116, 0.7);

    /* Floating toolbar - Bavarian wood */
    --toolbar-bg: rgba(93, 78, 55, 0.85);
    --toolbar-border: rgba(212, 165, 116, 0.3);
    --toolbar-shadow: rgba(93, 78, 55, 0.3);
    --toolbar-hover-bg: rgba(93, 78, 55, 1);
    --toolbar-hover-border: rgba(255, 174, 66, 0.6);
}

body {
    font-family: 'Nunito', sans-serif;
    background: linear-gradient(135deg, var(--wood-light) 0%, var(--caramel) 50%, var(--wood-dark) 100%);
    color: var(--wood-dark);
    overflow-x: hidden;
    min-height: 100vh;
}

/* Wood grain texture */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: 
        repeating-linear-gradient(90deg, rgba(139, 115, 85, 0.25) 0px, rgba(139, 115, 85, 0.25) 2px, transparent 2px, transparent 4px, rgba(160, 130, 95, 0.15) 4px, rgba(160, 130, 95, 0.15) 6px, transparent 6px, transparent 12px),
        radial-gradient(ellipse at 15% 20%, rgba(101, 67, 33, 0.3) 0%, transparent 8%),
        radial-gradient(ellipse at 45% 60%, rgba(101, 67, 33, 0.25) 0%, transparent 6%),
        radial-gradient(ellipse at 75% 35%, rgba(101, 67, 33, 0.28) 0%, transparent 7%),
        radial-gradient(ellipse at 85% 75%, rgba(101, 67, 33, 0.22) 0%, transparent 5%),
        repeating-linear-gradient(0deg, transparent 0px, transparent 180px, rgba(101, 67, 33, 0.3) 180px, rgba(101, 67, 33, 0.3) 184px, transparent 184px, transparent 190px),
        repeating-linear-gradient(90deg, rgba(160, 130, 95, 0.1) 0px, rgba(160, 130, 95, 0.1) 1px, transparent 1px, transparent 2px),
        repeating-linear-gradient(45deg, transparent 0px, transparent 100px, rgba(101, 67, 33, 0.08) 100px, rgba(101, 67, 33, 0.08) 102px);
    pointer-events: none;
    z-index: 0;
}

body::after {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(ellipse at 50% 30%, rgba(255, 174, 66, 0.15) 0%, transparent 60%),
        radial-gradient(ellipse at 20% 70%, rgba(244, 164, 96, 0.12) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 60%, rgba(222, 184, 135, 0.10) 0%, transparent 55%);
    pointer-events: none;
    z-index: 0;
    animation: warmGlow 6s ease-in-out infinite alternate;
}

@keyframes warmGlow {
    from { opacity: 0.8; }
    to { opacity: 1; }
}

@keyframes float {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    50% { transform: translateY(-20px) rotate(5deg); }
}

@keyframes cheers {
    0%, 100% { transform: rotate(0deg); }
    25% { transform: rotate(-15deg); }
    75% { transform: rotate(15deg); }
}

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

@keyframes shimmer {
    0% { background-position: -1000px 0; }
    100% { background-position: 1000px 0; }
}

.container {
    max-width: 1500px;
    margin: 0 auto;
    padding: 2rem;
    position: relative;
    z-index: 1;
}

/* ===================================
   LANDING PAGE
   =================================== */

.landing-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.landing-page .container {
    text-align: center;
    max-width: 900px;
}

.hero {
    margin-bottom: 3rem;
}

.hero-icon {
    font-size: 8rem;
    margin-bottom: 2rem;
    animation: float 3s ease-in-out infinite;
    filter: drop-shadow(0 10px 20px rgba(139, 115, 85, 0.3));
}

.main-title {
    font-family: 'Righteous', cursive;
    font-size: clamp(3rem, 10vw, 6rem);
    color: var(--honey);
    text-shadow: 
        3px 3px 0 var(--wood-dark),
        6px 6px 20px rgba(139, 115, 85, 0.5);
    margin-bottom: 1.5rem;
    line-height: 1.1;
}

.subtitle {
    font-family: 'Baloo 2', cursive;
    font-size: clamp(1.5rem, 4vw, 2.5rem);
    color: var(--moss-green);
    margin-bottom: 2rem;
    font-weight: 700;
}

.description {
    font-size: 1.4rem;
    color: var(--wood-dark);
    line-height: 1.8;
    margin-bottom: 3rem;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}

.features {
    display: none; /* Hide in beer garden, we show steps instead */
}

.onboarding-steps {
    margin-bottom: 3rem;
}

.steps-title {
    font-family: 'Righteous', cursive;
    font-size: 2rem;
    color: var(--honey);
    margin-bottom: 2rem;
}

.steps-list {
    display: flex;
    justify-content: space-around;
    list-style: none;
    flex-wrap: wrap;
    gap: 2rem;
}

.step {
    text-align: center;
    flex: 1;
    min-width: 150px;
}

.step-number {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, var(--honey), var(--amber-gold));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Baloo 2', cursive;
    font-size: 2rem;
    font-weight: 800;
    color: white;
    margin: 0 auto 1rem;
    box-shadow: 0 5px 15px rgba(255, 174, 66, 0.4);
}

.step-text {
    font-weight: 600;
    color: var(--wood-dark);
    font-size: 1.1rem;
}

.auth-form {
    background: var(--cream);
    border-radius: 30px;
    padding: 3rem;
    box-shadow: 
        0 20px 60px rgba(139, 115, 85, 0.3),
        inset 0 -5px 20px rgba(139, 115, 85, 0.1);
    border: 6px solid var(--wood-dark);
    position: relative;
    max-width: 600px;
    margin: 0 auto;
}

.auth-form::before {
    content: '🌿';
    position: absolute;
    top: -40px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 3rem;
    background: var(--cream);
    padding: 0 1rem;
    border-radius: 50%;
}

.form-title {
    font-family: 'Righteous', cursive;
    font-size: 2rem;
    color: var(--honey);
    margin-bottom: 2rem;
    text-align: center;
}

.form-label {
    font-family: 'Baloo 2', cursive;
    font-size: 1rem;
    font-weight: 700;
    color: var(--wood-dark);
    margin-bottom: 0.8rem;
    display: block;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.email-input {
    width: 100%;
    padding: 1.5rem;
    font-family: 'Nunito', sans-serif;
    font-size: 1.2rem;
    background: white;
    border: 4px solid var(--honey);
    border-radius: 20px;
    color: var(--wood-dark);
    margin-bottom: 1.5rem;
    transition: all 0.3s;
    box-shadow: inset 0 2px 10px rgba(0, 0, 0, 0.05);
}

.email-input:focus {
    outline: none;
    border-color: var(--amber-gold);
    box-shadow: 0 0 0 4px rgba(255, 174, 66, 0.2);
}

.primary-button {
    width: 100%;
    padding: 1.8rem;
    font-family: 'Baloo 2', cursive;
    font-size: 1.8rem;
    font-weight: 800;
    background: linear-gradient(135deg, var(--honey), var(--amber-gold));
    border: none;
    border-radius: 20px;
    color: white;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    transition: all 0.4s;
    box-shadow: 0 10px 30px rgba(255, 174, 66, 0.4);
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.primary-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
    animation: shimmer 2s infinite;
}

.primary-button:hover {
    transform: translateY(-5px) scale(1.02);
    box-shadow: 0 15px 40px rgba(255, 174, 66, 0.5);
}

/* ===================================
   DASHBOARD
   =================================== */

.dashboard {
    animation: fadeInUp 0.8s ease-out;
}

.user-header {
    background: var(--cream);
    border-radius: 30px;
    padding: 2rem;
    margin-bottom: 3rem;
    box-shadow: 0 10px 40px rgba(139, 115, 85, 0.2);
    border: 5px solid var(--wood-dark);
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 2rem;
}

.user-info {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.user-avatar {
    width: 100px;
    height: 100px;
    background: linear-gradient(135deg, var(--honey), var(--caramel));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3rem;
    box-shadow: 0 8px 25px rgba(255, 174, 66, 0.3);
    border: 4px solid var(--wood-dark);
}

.user-details {
    flex: 1;
}

.user-name {
    font-family: 'Righteous', cursive;
    font-size: 2.5rem;
    color: var(--honey);
    text-shadow: 2px 2px 0 var(--wood-dark);
}

.user-email {
    color: var(--wood-dark);
    opacity: 0.8;
    margin-top: 0.5rem;
    font-size: 1.1rem;
}

.user-stats {
    display: flex;
    gap: 3rem;
}

.stat {
    text-align: center;
    background: white;
    padding: 1.5rem 2rem;
    border-radius: 20px;
    border: 3px solid var(--honey);
    box-shadow: 0 5px 15px rgba(255, 174, 66, 0.2);
}

.stat-value {
    font-family: 'Baloo 2', cursive;
    font-size: 3rem;
    font-weight: 800;
    color: var(--amber-gold);
    line-height: 1;
    display: block;
}

.stat-label {
    font-size: 0.95rem;
    color: var(--wood-dark);
    font-weight: 600;
    margin-top: 0.5rem;
    text-transform: uppercase;
}

.actions {
    display: flex;
    gap: 2rem;
    margin-bottom: 3rem;
    flex-wrap: wrap;
}

.action-button {
    flex: 1;
    min-width: 250px;
    background: var(--cream);
    border-radius: 25px;
    padding: 2.5rem;
    text-align: center;
    border: 4px solid var(--wood-dark);
    cursor: pointer;
    transition: all 0.4s;
    box-shadow: 0 10px 30px rgba(139, 115, 85, 0.2);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
}

.action-button:hover {
    transform: translateY(-8px) scale(1.03);
    box-shadow: 0 15px 40px rgba(255, 174, 66, 0.4);
}

.action-icon {
    font-size: 4rem;
    display: block;
}

.action-text {
    font-family: 'Baloo 2', cursive;
    font-size: 1.8rem;
    font-weight: 800;
    color: var(--honey);
}

.debts-section {
    background: var(--wood-light);
    border-radius: 40px;
    padding: 3rem;
    margin-bottom: 3rem;
    box-shadow: 
        0 20px 60px rgba(139, 115, 85, 0.4),
        inset 0 5px 30px rgba(139, 115, 85, 0.2);
    border: 8px solid var(--wood-dark);
}

.section-title {
    font-family: 'Righteous', cursive;
    font-size: 2.5rem;
    color: var(--honey);
    text-shadow: 2px 2px 0 var(--wood-dark);
    margin-bottom: 2rem;
    text-align: center;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
}

.section-title::before,
.section-title::after {
    content: '🌟';
    font-size: 2rem;
}

.debts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    padding: 2rem;
}

.debt-card {
    background: var(--cream);
    border-radius: 25px;
    padding: 2rem;
    box-shadow: 0 10px 30px rgba(139, 115, 85, 0.3);
    border: 4px solid var(--wood-dark);
    transition: all 0.4s;
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.debt-card::before {
    content: '🍺';
    position: absolute;
    font-size: 150px;
    opacity: 0.1;
    right: -30px;
    bottom: -30px;
    transform: rotate(-15deg);
}

.debt-card:hover {
    transform: translateY(-10px) rotate(2deg);
    box-shadow: 0 15px 40px rgba(255, 174, 66, 0.4);
}

.card-visual {
    display: none; /* Beer mug visual integrated in ::before pseudo */
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: start;
    margin-bottom: 1.5rem;
    position: relative;
    z-index: 1;
}

.card-person {
    font-family: 'Baloo 2', cursive;
    font-size: 2rem;
    font-weight: 800;
    color: var(--honey);
    text-shadow: 1px 1px 0 var(--wood-dark);
}

.card-amount {
    font-size: 2.5rem;
    display: flex;
    gap: 0.3rem;
}

.card-message {
    color: var(--wood-dark);
    font-size: 1.1rem;
    line-height: 1.7;
    margin-bottom: 1.5rem;
    position: relative;
    z-index: 1;
}

.card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 1rem;
    border-top: 2px dashed var(--wood-dark);
    position: relative;
    z-index: 1;
}

.card-date {
    font-weight: 700;
    color: var(--moss-green);
    font-size: 1rem;
}

.card-action {
    padding: 0.9rem 2rem;
    font-family: 'Baloo 2', cursive;
    font-size: 1rem;
    font-weight: 700;
    background: linear-gradient(135deg, var(--honey), var(--amber-gold));
    border: none;
    border-radius: 15px;
    color: white;
    cursor: pointer;
    transition: all 0.3s;
    box-shadow: 0 5px 15px rgba(255, 174, 66, 0.3);
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}

.card-action:hover {
    transform: scale(1.1);
    animation: cheers 0.6s ease-in-out;
    box-shadow: 0 8px 20px rgba(255, 174, 66, 0.5);
}

/* Beer Animation */
.beer-animation {
    display: none;
    position: fixed;
    bottom: 20%;
    left: -300px;
    font-size: 120px;
    pointer-events: none;
    z-index: 1000;
    filter: drop-shadow(0 0 20px var(--honey));
    animation: beerSlide 4s ease-in-out;
}

@keyframes beerSlide {
    0% { transform: translateX(-300px) rotate(-10deg); opacity: 0; }
    30% { opacity: 1; }
    70% { opacity: 1; }
    100% { transform: translateX(calc(100vw + 100px)) rotate(10deg); opacity: 0; }
}

/* Theme Selector */
.theme-selector {
    background: var(--cream);
    border-radius: 25px;
    padding: 2rem;
    margin-top: 4rem;
    border: 4px solid var(--wood-dark);
    text-align: center;
}

.theme-selector h3 {
    font-family: 'Righteous', cursive;
    font-size: 2rem;
    color: var(--honey);
    margin-bottom: 1.5rem;
}

.theme-selector button {
    margin: 0.5rem;
    padding: 1rem 2rem;
    font-family: 'Baloo 2', cursive;
    font-size: 1rem;
    font-weight: 700;
    background: linear-gradient(135deg, var(--honey), var(--amber-gold));
    border: none;
    border-radius: 15px;
    color: white;
    cursor: pointer;
    transition: all 0.3s;
    box-shadow: 0 5px 15px rgba(255, 174, 66, 0.3);
}

.theme-selector button:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(255, 174, 66, 0.5);
}

/* Mobile Responsiveness */
@media (max-width: 768px) {
    .container {
        padding: 1rem;
    }

    .hero-icon {
        font-size: 5rem;
    }

    .main-title {
        font-size: 3rem;
    }

    .auth-form {
        padding: 2rem;
    }

    .steps-list {
        flex-direction: column;
    }

    .user-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .user-stats {
        width: 100%;
        justify-content: space-around;
    }

    .debts-grid {
        grid-template-columns: 1fr;
        padding: 1rem;
    }

    .actions {
        flex-direction: column;
    }
}
