/* ==========================================
   RETRO CARTOON AUTH STYLES
   Inspired by 1930s-1960s Classic Animation
   ========================================== */

/* Base body with vintage paper texture aesthetic */
body {
    height: calc(100vh - 68px);
    overflow-y: auto;
    background: url(/build/assets/wp2077318.jpg) no-repeat fixed;
    background-position: 50%;
    background-size: cover;
    font-family: 'Comic Sans MS', 'Marker Felt', 'Chalkboard SE', cursive, sans-serif;
    /* Add vintage film grain overlay effect */
    position: relative;
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        repeating-linear-gradient(0deg, transparent, transparent 2px, rgba(0,0,0,.03) 2px, rgba(0,0,0,.03) 4px),
        repeating-linear-gradient(90deg, transparent, transparent 2px, rgba(0,0,0,.03) 2px, rgba(0,0,0,.03) 4px);
    pointer-events: none;
    z-index: 1;
}

/* Bouncy cartoon moon with exaggerated animation */
.moon {
    top: 35%;
    right: 5%;
    position: fixed;
    animation: CartoonBounceLeft 2s cubic-bezier(0.68, -0.55, 0.265, 1.55) infinite;
    filter: drop-shadow(0 0 20px #ffd700) brightness(1.2);
    z-index: 2;
}

@media(min-width: 0em) and (max-width: 46.87em) {
    .moon {
        visibility: hidden;
    }
}

@media(min-width: 46.88em) and (max-width: 67.99em) {
    .moon {
        width: 300px;
        right: -100px;
        top: 400px;
    }
}

@media(min-width: 200em) and (max-width: 299.99em) {
    .moon {
        top: 45%;
        right: 500px;
    }
}

/* Wobbly cartoon saturn with personality */
.saturn {
    top: 50px;
    left: 0;
    position: fixed;
    animation: CartoonWobbleRight 3s cubic-bezier(0.68, -0.55, 0.265, 1.55) infinite;
    filter: drop-shadow(0 0 15px #ff6b6b) hue-rotate(20deg);
    z-index: 2;
}

@media(min-width: 20em) and (max-width: 67.99em) {
    .saturn {
        top: 50px;
        left: -100px;
    }
}

@media(min-width: 200em) and (max-width: 299.99em) {
    .saturn {
        top: 300px;
        left: 400px;
    }
}

/* Exaggerated cartoon bounce animations */
@keyframes CartoonBounceLeft {
    0%, 100% {
        transform: translateY(0) rotate(0deg) scale(1);
    }
    25% {
        transform: translate(20px, -15px) rotate(5deg) scale(1.05);
    }
    50% {
        transform: translate(10px, 15px) rotate(-3deg) scale(0.98);
    }
    75% {
        transform: translate(15px, -8px) rotate(2deg) scale(1.02);
    }
}

@keyframes CartoonWobbleRight {
    0%, 100% {
        transform: translateY(0) rotate(0deg) scale(1);
    }
    20% {
        transform: translate(-15px, 10px) rotate(-8deg) scale(1.03);
    }
    40% {
        transform: translate(-8px, -12px) rotate(5deg) scale(0.97);
    }
    60% {
        transform: translate(-12px, 8px) rotate(-4deg) scale(1.02);
    }
    80% {
        transform: translate(-5px, -5px) rotate(3deg) scale(0.99);
    }
}

/* Comic book style form with bold outlines */
.auth-form {
    background: linear-gradient(135deg, #fffacd 0%, #fff8dc 100%);
    border: 6px solid #000;
    box-shadow: 
        8px 8px 0 #000,
        12px 12px 0 rgba(255, 215, 0, 0.4),
        0 0 40px rgba(255, 215, 0, 0.3);
    width: min(100vw - 20px, 420px);
    margin: 60px auto;
    border-radius: 20px;
    opacity: 1;
    position: relative;
    z-index: 10;
    transform: rotate(-0.5deg);
}

/* Add cartoon sparkle effect */
.auth-form::before {
    content: '★';
    position: absolute;
    top: -20px;
    right: 20px;
    font-size: 40px;
    color: #ffd700;
    animation: StarTwinkle 1.5s ease-in-out infinite;
    text-shadow: 
        0 0 10px #fff,
        0 0 20px #ffd700,
        0 0 30px #ffd700;
}

@keyframes StarTwinkle {
    0%, 100% {
        transform: scale(1) rotate(0deg);
        opacity: 1;
    }
    50% {
        transform: scale(1.3) rotate(180deg);
        opacity: 0.7;
    }
}

@media(min-height: 0em) and (max-height: 36.56em) {
    .auth-form {
        margin: 0 auto 8px;
    }
}

.auth-form__form {
    padding: 40px 30px;
    display: flex;
    flex-direction: column;
    gap: 20px;
    background: repeating-linear-gradient(
        45deg,
        transparent,
        transparent 10px,
        rgba(255, 215, 0, 0.05) 10px,
        rgba(255, 215, 0, 0.05) 20px
    );
}

/* Bold comic book header tabs */
.auth-form__header {
    display: flex;
    justify-content: space-around;
    background: linear-gradient(180deg, #ff6b6b 0%, #ee5555 100%);
    border: 4px solid #000;
    border-radius: 15px 15px 0 0;
    margin: -4px -4px 0 -4px;
}

.auth-form__header-item {
    padding: 16px;
    text-decoration: none;
    text-align: center;
    line-height: 1.2;
    font-size: 18px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.15ch;
    transition: all 0.15s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    color: #fff;
    background-color: transparent;
    border: none;
    cursor: pointer;
    width: 100%;
    text-shadow: 
        2px 2px 0 #000,
        -1px -1px 0 #000,
        1px -1px 0 #000,
        -1px 1px 0 #000;
    position: relative;
}

.auth-form__header-item::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 4px;
    background: #ffd700;
    transition: all 0.3s;
    transform: translateX(-50%);
}

.auth-form__header-item:hover {
    transform: translateY(-4px) scale(1.05);
    text-decoration: none;
    filter: brightness(1.2);
}

.auth-form__header-item:hover::after {
    width: 80%;
}

.auth-form__header-item:active {
    transform: scale(0.92) translateY(2px);
    animation: PopEffect 0.3s ease-out;
}

@keyframes PopEffect {
    0% { transform: scale(1); }
    50% { transform: scale(0.88); }
    100% { transform: scale(0.92); }
}

/* Retro comic book footer */
.auth-form__footer {
    display: flex;
    flex-direction: column;
    background: linear-gradient(180deg, #87ceeb 0%, #6eb5d6 100%);
    border: 4px solid #000;
    border-radius: 0 0 15px 15px;
    margin: 0 -4px -4px -4px;
}

.auth-form__footer-item {
    padding: 14px;
    text-decoration: none;
    text-align: center;
    line-height: 1.2;
    font-size: 16px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.1ch;
    transition: all 0.2s;
    color: #000;
    background-color: transparent;
    border: none;
    cursor: pointer;
    text-shadow: 1px 1px 0 rgba(255, 255, 255, 0.5);
}

.auth-form__footer-item:last-child {
    border-bottom-left-radius: 11px;
    border-bottom-right-radius: 11px;
    padding: 30px 12px;
    background: linear-gradient(180deg, rgba(255, 215, 0, 0.3) 0%, rgba(255, 215, 0, 0.1) 100%);
}

.auth-form__footer-item:hover {
    background-color: rgba(255, 255, 255, 0.4);
    transform: scale(1.03);
    text-decoration: underline;
    text-decoration-color: #000;
    text-decoration-thickness: 3px;
    text-decoration-style: wavy;
}

.auth-form__button-container {
    display: flex;
    justify-content: space-around;
}

/* Big bold cartoon action button */
.auth-form__primary-button {
    height: 58px;
    border-radius: 29px;
    background: linear-gradient(180deg, #ff6b6b 0%, #ee5555 100%);
    border: 5px solid #000;
    box-shadow: 
        4px 4px 0 #000,
        8px 8px 0 rgba(255, 107, 107, 0.3);
    width: 100%;
    color: #fff;
    font-weight: 900;
    font-size: 20px;
    text-transform: uppercase;
    letter-spacing: 0.15ch;
    transition: all 0.2s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    margin-top: 24px;
    cursor: pointer;
    text-shadow: 
        2px 2px 0 #000,
        -1px -1px 0 #000,
        1px -1px 0 #000,
        -1px 1px 0 #000;
    position: relative;
}

.auth-form__primary-button::before {
    content: '→';
    position: absolute;
    right: 20px;
    font-size: 24px;
    transition: transform 0.3s;
}

.auth-form__primary-button:hover {
    background: linear-gradient(180deg, #ffd700 0%, #ffcc00 100%);
    transform: translateY(-4px) scale(1.02);
    box-shadow: 
        6px 10px 0 #000,
        10px 14px 0 rgba(255, 215, 0, 0.3);
    animation: ButtonWiggle 0.5s ease-in-out;
}

.auth-form__primary-button:hover::before {
    transform: translateX(5px);
}

@keyframes ButtonWiggle {
    0%, 100% { transform: translateY(-4px) scale(1.02) rotate(0deg); }
    25% { transform: translateY(-4px) scale(1.02) rotate(-2deg); }
    75% { transform: translateY(-4px) scale(1.02) rotate(2deg); }
}

.auth-form__primary-button:active {
    transform: translateY(2px) scale(0.98);
    box-shadow: 
        2px 2px 0 #000,
        4px 4px 0 rgba(255, 107, 107, 0.3);
}

.auth-form__button--text {
    padding: 14px 22px;
    border-radius: 20px;
    border: 3px solid #000;
    color: #000;
    font-weight: 800;
    font-size: 16px;
    text-transform: uppercase;
    transition: all 0.2s;
    background: linear-gradient(135deg, #fff 0%, #f0f0f0 100%);
    cursor: pointer;
    box-shadow: 3px 3px 0 #000;
}

.auth-form__button--text:hover {
    background: linear-gradient(135deg, #ffd700 0%, #ffcc00 100%);
    transform: translateY(-2px);
    box-shadow: 4px 6px 0 #000;
}

/* Bold retro labels */
.auth-form__label {
    margin-left: 14px;
    font-size: 18px;
    color: #000;
    font-weight: 900;
    width: 100%;
    text-transform: uppercase;
    letter-spacing: 0.08ch;
    text-shadow: 1px 1px 0 rgba(255, 255, 255, 0.7);
}

.auth-form__text-input-group,
.auth-form__select-group,
.auth-form__textarea-group {
    display: flex;
    flex-direction: column;
    margin: 0;
    position: relative;
}

/* Comic book style inputs */
.auth-form__text-input,
.auth-form__select {
    border-radius: 15px;
    height: 48px;
    padding: 8px 18px;
    margin: 6px 0;
    border: 4px solid #000;
    box-sizing: border-box;
    background: linear-gradient(135deg, #fff 0%, #fffacd 100%);
    outline: none;
    transition: all 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    font-weight: 700;
    font-size: 16px;
    color: #000;
    font-family: 'Comic Sans MS', 'Marker Felt', cursive, sans-serif;
    box-shadow: inset 2px 2px 5px rgba(0, 0, 0, 0.1);
}

.auth-form__text-input:focus,
.auth-form__select:focus,
.auth-form__textarea:focus {
    box-shadow: 
        0 0 0 4px #ffd700,
        inset 2px 2px 5px rgba(0, 0, 0, 0.1);
    transform: scale(1.02);
    background: linear-gradient(135deg, #fff 0%, #fff8dc 100%);
    border-color: #ffd700;
}

/* Animated focus state */
@keyframes InputPulse {
    0%, 100% { box-shadow: 0 0 0 4px #ffd700; }
    50% { box-shadow: 0 0 0 6px #ffd700; }
}

.auth-form__text-input:focus,
.auth-form__select:focus,
.auth-form__textarea:focus {
    animation: InputPulse 1.5s ease-in-out infinite;
}

/* Retro checkbox styling */
.auth-form__checkbox-input-group {
    margin: 0;
    display: flex;
    align-items: center;
}

.auth-form__checkbox-input {
    margin-left: 12px;
    margin-right: 8px;
    width: 24px;
    height: 24px;
    cursor: pointer;
    border: 3px solid #000;
    appearance: none;
    background: #fff;
    border-radius: 5px;
    position: relative;
}

.auth-form__checkbox-input:checked {
    background: #ffd700;
}

.auth-form__checkbox-input:checked::after {
    content: '✓';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 20px;
    font-weight: 900;
    color: #000;
}

.auth-form__checkbox-input + .auth-form__label {
    margin-left: 0;
    cursor: pointer;
}

/* Comic panel fieldset */
.auth-form__fieldset {
    border-radius: 15px;
    border: 5px solid #000;
    padding: 60px 20px 20px;
    box-shadow: 
        4px 4px 0 #000,
        0 0 20px rgba(255, 215, 0, 0.3);
    position: relative;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.8) 0%, rgba(255, 250, 205, 0.8) 100%);
}

.auth-form__legend {
    font-size: 22px;
    font-weight: 900;
    margin: 0;
    color: #000;
    position: absolute;
    top: 15px;
    left: 20px;
    border: none;
    text-transform: uppercase;
    letter-spacing: 0.1ch;
    text-shadow: 2px 2px 0 rgba(255, 215, 0, 0.5);
}

.auth-form__textarea {
    height: 300px;
    border-radius: 15px;
    padding: 12px 18px;
    margin: 6px 0;
    border: 4px solid #000;
    box-sizing: border-box;
    background: linear-gradient(135deg, #fff 0%, #fffacd 100%);
    outline: none;
    transition: all 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    font-weight: 700;
    font-size: 16px;
    color: #000;
    font-family: 'Comic Sans MS', 'Marker Felt', cursive, sans-serif;
    box-shadow: inset 2px 2px 5px rgba(0, 0, 0, 0.1);
    resize: vertical;
}

/* Vintage logo branding */
.auth-form__branding {
    text-decoration: none;
    color: #ff6b6b;
    display: flex;
    column-gap: 5px;
    align-items: center;
    font-size: 3.5rem;
    flex-direction: column;
    margin-bottom: 16px;
    filter: drop-shadow(3px 3px 0 #000);
}

.auth-form__site-logo {
    color: #000;
    font-weight: 900;
    font-size: 4rem;
    font-family: 'Impact', 'Arial Black', sans-serif;
    text-transform: uppercase;
    letter-spacing: 0.15ch;
    line-height: 1;
    background: linear-gradient(180deg, #ff6b6b 0%, #ffd700 50%, #87ceeb 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: none;
    filter: none;
    position: relative;
}

.auth-form__site-logo::before {
    content: attr(data-text);
    position: absolute;
    left: 3px;
    top: 3px;
    z-index: -1;
    -webkit-text-fill-color: #000;
}

/* Comic book style error messages */
.auth-form__errors {
    list-style-type: none;
    margin: 0;
    padding: 16px 12px;
}

.auth-form__important-infos {
    list-style-type: none;
    margin: 0;
    padding: 0 0 20px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.auth-form__error,
.auth-form__important-info {
    color: #fff;
    background: linear-gradient(135deg, #ff6b6b 0%, #ee5555 100%);
    font-weight: 800;
    font-size: 17px;
    padding: 12px 16px;
    border: 4px solid #000;
    border-radius: 12px;
    box-shadow: 3px 3px 0 #000;
    text-transform: uppercase;
    letter-spacing: 0.05ch;
    text-shadow: 1px 1px 0 #000;
    position: relative;
}

.auth-form__error::before,
.auth-form__important-info::before {
    content: '⚠';
    margin-right: 8px;
    font-size: 20px;
    animation: WarningBlink 1s ease-in-out infinite;
}

@keyframes WarningBlink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.auth-form__info {
    color: #000;
    background: linear-gradient(135deg, #ffd700 0%, #ffcc00 100%);
    font-size: 16px;
    font-weight: 700;
    padding: 12px 16px;
    border: 3px solid #000;
    border-radius: 12px;
    box-shadow: 3px 3px 0 #000;
}

/* Hide cloak utility */
[x-cloak] {
    display: none !important;
}

/* Add vintage halftone dot pattern overlay */
.auth-form::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: radial-gradient(circle, transparent 1px, rgba(0, 0, 0, 0.02) 1px);
    background-size: 4px 4px;
    pointer-events: none;
    border-radius: 20px;
}