/* style.css - Modern Brutalism & Advanced Motion */

:root {
    --ease-squish: cubic-bezier(0.5, -0.6, 0.2, 1.5); /* Efek memantul */
    --ease-smooth: cubic-bezier(0.22, 1, 0.36, 1);    /* Apple-like smooth */
}

/* Custom Scrollbar */
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: #f4f4f4; }
::-webkit-scrollbar-thumb { background: #ccc; border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: #111; }

/* Utilities */
.brutal-border { border: 2px solid #111; }
.grid-pattern {
    background-image: radial-gradient(#111 1px, transparent 1px);
    background-size: 24px 24px;
}

/* --- ANIMATIONS --- */

/* 1. Page Entry (Slide Up + Fade) */
@keyframes enter {
    0% { opacity: 0; transform: translateY(20px); }
    100% { opacity: 1; transform: translateY(0); }
}

/* 2. Staggered Elements */
.stagger-anim {
    opacity: 0;
    animation: enter 0.6s var(--ease-smooth) forwards;
    animation-delay: calc(var(--delay) * 100ms + 300ms);
}

/* 3. Modern Loader */
.loader {
    width: 48px;
    height: 48px;
    border: 5px solid #111;
    border-bottom-color: transparent;
    border-radius: 50%;
    animation: rotation 1s linear infinite;
}
@keyframes rotation { 0% { transform: rotate(0deg); } 100% { transform: rotate(360deg); } }

/* --- COMPONENTS --- */

/* Brutalist Inputs */
.brutal-input {
    background: transparent;
    border-bottom: 2px solid #ccc;
    transition: all 0.3s var(--ease-smooth);
}
.brutal-input:focus {
    outline: none;
    border-bottom-color: #111;
    background: rgba(255,255,255,0.5);
    padding-left: 12px; /* Slight slide on focus */
}

/* Custom Checkbox (Square & Bold) */
.checkbox-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    cursor: pointer;
}
.checkbox-container input { display: none; }
.checkmark {
    height: 24px;
    width: 24px;
    border: 2px solid #ccc;
    background-color: transparent;
    transition: all 0.2s var(--ease-squish);
}
.checkbox-container:hover .checkmark { border-color: #111; }
.checkbox-container input:checked ~ .checkmark {
    background-color: #111;
    border-color: #111;
    transform: scale(1.1);
    box-shadow: 4px 4px 0 rgba(0,0,0,0.1);
}

/* Brutalist Buttons */
.brutal-btn-white, .brutal-btn-black {
    position: relative;
    padding: 16px;
    font-family: 'Space Grotesk', sans-serif;
    font-weight: 700;
    text-transform: uppercase;
    font-size: 0.875rem;
    border: 2px solid #111;
    cursor: pointer;
    transition: all 0.2s var(--ease-smooth);
    box-shadow: 6px 6px 0 #111;
    display: flex;
    justify-content: center;
    align-items: center;
}

.brutal-btn-white { background: #fff; color: #111; }
.brutal-btn-black { background: #111; color: #fff; }

/* Button Hover State */
.brutal-btn-white:hover, .brutal-btn-black:hover {
    transform: translate(-2px, -2px);
    box-shadow: 8px 8px 0 #111;
}

/* Button Active (Click) State */
.brutal-btn-white:active, .brutal-btn-black:active {
    transform: translate(4px, 4px);
    box-shadow: 0px 0px 0 #111;
}

/* Toast Animation */
.toast-visible {
    opacity: 1 !important;
    transform: translate(-50%, 0) !important;
}

/* History Items */
.history-item {
    transition: transform 0.2s var(--ease-squish);
}
.history-item:hover {
    transform: scale(1.15) rotate(3deg);
    z-index: 10;
    border-color: #111;
}