/* assets/css/signup_user.css - Coffee Theme Customer Signup */
/* ==============================
   ROOT VARIABLES - COFFEE THEME
============================== */
:root {
    /* Coffee Theme Color Palette */
    --primary-brown: #6F4E37;      /* Coffee / Espresso */
    --dark-brown: #4B3D2A;         /* Deep Roast */
    --light-cream: #ECE0D1;        /* Creamy Latte */
    --beige: #DBC1AC;              /* Warm Beige */
    --accent-brown: #967259;       /* Mocha Accent */
    --text-dark: #38220F;          /* Dark Roast Text */
    --white: #FFFFFF;
    --off-white: #F9F5F0;         /* Soft Milk Foam */
    --success: #8B6F47;            /* Warm Golden Success */
    --error: #A0522D;              /* Sienna Error */
    --shadow: rgba(111, 78, 55, 0.15);
    --border: #DBC1AC;
    --input-bg: #F9F5F0;
    --hover-brown: #5A3E2E;
    --radius: 12px;
}

/* ==============================
   RESET & BASE
============================== */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    margin: 0;
    min-height: 100vh;
    font-family: 'Segoe UI', 'Roboto', system-ui, sans-serif;
    background: var(--light-cream);
    display: flex;
    justify-content: center;
    align-items: center;
    color: var(--text-dark);
    line-height: 1.6;
    position: relative;
    overflow-x: hidden;
}

/* Coffee Bean Pattern Background */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        radial-gradient(circle at 10% 20%, rgba(150, 114, 89, 0.03) 0%, transparent 15%),
        radial-gradient(circle at 90% 80%, rgba(219, 193, 172, 0.03) 0%, transparent 15%),
        radial-gradient(circle at 30% 60%, rgba(111, 78, 55, 0.02) 0%, transparent 12%),
        radial-gradient(circle at 70% 40%, rgba(139, 111, 71, 0.02) 0%, transparent 12%);
    z-index: -1;
    pointer-events: none;
}

/* Lock scroll when modal open */
body.modal-open {
    overflow: hidden;
}

body.modal-open::after {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(75, 61, 42, 0.6);
    backdrop-filter: blur(4px);
    z-index: 1999;
}

/* ==============================
   SIGNUP CONTAINER
============================== */
.signup-container {
    width: 100%;
    max-width: 440px;
    background: var(--off-white);
    padding: 35px 30px;
    border-radius: var(--radius);
    box-shadow: 
        0 12px 35px rgba(111, 78, 55, 0.18),
        0 4px 15px rgba(111, 78, 55, 0.1),
        inset 0 1px 0 rgba(255, 255, 255, 0.4);
    position: relative;
    z-index: 1;
    border: 1px solid rgba(219, 193, 172, 0.4);
    backdrop-filter: blur(10px);
    margin: 20px;
}

/* Coffee mug decorative element */
.signup-container::before {
    content: '';
    position: absolute;
    top: -50px;
    left: 50%;
    transform: translateX(-50%);
    width: 100px;
    height: 80px;
    background: linear-gradient(135deg, var(--accent-brown), var(--primary-brown));
    clip-path: polygon(0 20%, 100% 20%, 85% 100%, 15% 100%);
    border-radius: 50% 50% 0 0;
    z-index: -1;
    box-shadow: 0 8px 20px var(--shadow);
}

/* Coffee steam animation */
.signup-container::after {
    content: '';
    position: absolute;
    top: -80px;
    left: 50%;
    transform: translateX(-50%);
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.8);
    border-radius: 50% 50% 0 0;
    filter: blur(8px);
    animation: steamRise 4s infinite ease-in-out;
    z-index: -1;
}

@keyframes steamRise {
    0%, 100% { 
        opacity: 0.3; 
        transform: translateX(-50%) translateY(0);
    }
    50% { 
        opacity: 0.7; 
        transform: translateX(-50%) translateY(-20px);
    }
}

/* ==============================
   TOASTER
============================== */
#toaster-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 3000;
    display: flex;
    flex-direction: column;
    gap: 12px;
    max-width: 380px;
    width: 90%;
    pointer-events: none;
}

/* Individual Toast */
.toast {
    padding: 16px 20px;
    border-radius: 14px;
    font-weight: 600;
    font-size: 15px;
    min-width: 240px;
    max-width: 100%;
    color: var(--white);
    backdrop-filter: blur(10px);
    box-shadow: 
        0 10px 30px rgba(111, 78, 55, 0.25),
        0 4px 15px rgba(111, 78, 55, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.1);
    position: relative;
    overflow: hidden;
    opacity: 0;
    transform: translateX(100%);
    transition: all 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    pointer-events: auto;
}

.toast.show {
    opacity: 1;
    transform: translateX(0);
}

.toast::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 6px;
    height: 100%;
    background: rgba(255, 255, 255, 0.3);
}

/* Colors */
.toast.success { background: linear-gradient(135deg, var(--success), #A6895B); border-left: 6px solid #7D5E3A; }
.toast.info    { background: linear-gradient(135deg, var(--accent-brown), #B89A7A); border-left: 6px solid #8B6F47; }
.toast.error   { background: linear-gradient(135deg, var(--error), #C1734D); border-left: 6px solid #8B4513; }

/* ==============================
   PAGE TITLE
============================== */
.page-title {
    text-align: center;
    margin-bottom: 30px;
    position: relative;
}

.page-title h2 {
    font-size: 28px;
    margin-bottom: 10px;
    color: var(--primary-brown);
    font-weight: 600;
    position: relative;
    display: inline-block;
    padding-bottom: 10px;
}

.page-title h2::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 70px;
    height: 3px;
    background: linear-gradient(to right, var(--accent-brown), var(--success));
    border-radius: 2px;
}

.page-title p {
    color: var(--accent-brown);
    font-size: 15px;
    opacity: 0.9;
    margin: 0;
}

/* ==============================
   FORM INPUTS
============================== */
.signup-form {
    margin-top: 20px;
}

.signup-form input {
    width: 100%;
    padding: 16px 18px;
    margin-bottom: 18px;
    border-radius: 10px;
    border: 1px solid var(--border);
    font-size: 16px;
    background: var(--input-bg);
    color: var(--text-dark);
    transition: all 0.3s ease;
    box-shadow: inset 0 2px 4px rgba(111, 78, 55, 0.05);
}

.signup-form input::placeholder {
    color: #A08B7A;
    opacity: 0.7;
}

.signup-form input:focus {
    outline: none;
    border-color: var(--accent-brown);
    box-shadow: 
        0 0 0 3px rgba(150, 114, 89, 0.2),
        inset 0 2px 4px rgba(111, 78, 55, 0.05);
    background-color: var(--white);
}

.signup-form input:hover {
    border-color: var(--accent-brown);
}

/* ==============================
   PASSWORD FIELD
============================== */
.password-container {
    position: relative;
    margin-bottom: 18px;
}

.password-container input {
    padding-right: 50px;
}

.toggle-password {
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
    cursor: pointer;
    background: transparent;
    border: none;
    color: var(--accent-brown);
    padding: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    border-radius: 6px;
    padding-bottom: 20px;
}

.toggle-password:hover {
    transform: translateY(-50%) scale(1.1);
}

.toggle-password svg {
    width: 22px;
    height: 22px;
}

.toggle-password svg path,
.toggle-password svg circle {
    stroke: currentColor;
    fill: none;
    transition: stroke 0.3s ease;
}

/* ==============================
   FORM VALIDATION STYLES
============================== */
.signup-form input:valid {
    border-color: rgba(139, 111, 71, 0.4);
}

.signup-form input:invalid:not(:placeholder-shown):not(:focus) {
    border-color: rgba(160, 82, 45, 0.4);
}

/* ==============================
   BUTTONS
============================== */
.btn {
    width: 100%;
    padding: 16px;
    border-radius: 10px;
    border: none;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    letter-spacing: 0.5px;
    margin-top: 10px;
    box-shadow: 
        0 4px 12px rgba(111, 78, 55, 0.2),
        0 2px 4px rgba(111, 78, 55, 0.1);
}

.btn::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: left 0.7s ease;
}

.btn:hover::after {
    left: 100%;
}

/* Primary Button */
.btn.primary {
    background: linear-gradient(135deg, var(--primary-brown), var(--dark-brown));
    color: var(--white);
    border: 1px solid rgba(111, 78, 55, 0.3);
}

.btn.primary:hover {
    background: linear-gradient(135deg, var(--hover-brown), var(--primary-brown));
    transform: translateY(-2px);
    box-shadow: 
        0 6px 20px rgba(111, 78, 55, 0.25),
        0 4px 8px rgba(111, 78, 55, 0.15);
}

.btn.primary:active {
    transform: translateY(0);
    box-shadow: 
        0 2px 8px rgba(111, 78, 55, 0.2),
        0 1px 3px rgba(111, 78, 55, 0.1);
}

/* Success Button */
.btn.success {
    background: linear-gradient(135deg, var(--success), #A6895B);
    color: var(--white);
    border: 1px solid rgba(139, 111, 71, 0.3);
}

.btn.success:hover {
    background: linear-gradient(135deg, #9C7C4F, var(--success));
    transform: translateY(-2px);
    box-shadow: 
        0 6px 20px rgba(139, 111, 71, 0.25),
        0 4px 8px rgba(139, 111, 71, 0.15);
}

/* ==============================
   SIGN IN LINK
============================== */
.signin-link {
    margin-top: 25px;
    text-align: center;
    font-size: 15px;
    color: var(--accent-brown);
    padding-top: 20px;
    border-top: 1px solid rgba(219, 193, 172, 0.5);
}

.signin-link a {
    color: var(--primary-brown);
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    padding: 4px 8px;
    border-radius: 6px;
    position: relative;
    display: inline-block;
}

.signin-link a::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--primary-brown);
    transition: width 0.3s ease;
}

.signin-link a:hover {
    color: var(--dark-brown);
    background-color: rgba(219, 193, 172, 0.1);
}

.signin-link a:hover::after {
    width: 100%;
}

/* ==============================
   OTP MODAL - COFFEE THEME
============================== */
.modal-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(75, 61, 42, 0.7);
    justify-content: center;
    align-items: center;
    z-index: 2000;
    padding: 20px;
    backdrop-filter: blur(5px);
}

.modal-box {
    background: var(--off-white);
    width: 90%;
    max-width: 420px;
    padding: 30px;
    border-radius: 14px;
    box-shadow: 
        0 20px 40px rgba(111, 78, 55, 0.25),
        0 8px 20px rgba(111, 78, 55, 0.15);
    border: 1px solid rgba(219, 193, 172, 0.4);
    animation: modalSlideIn 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: translateY(-30px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid var(--border);
}

.modal-header h3 {
    margin: 0;
    font-size: 22px;
    color: var(--primary-brown);
    font-weight: 600;
}

.modal-close {
    background: none;
    border: none;
    font-size: 28px;
    cursor: pointer;
    color: var(--accent-brown);
    padding: 0;
    line-height: 1;
    transition: all 0.3s ease;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-close:hover {
    color: var(--primary-brown);
    background-color: rgba(219, 193, 172, 0.2);
    transform: rotate(90deg);
}

.modal-instructions {
    color: var(--accent-brown);
    font-size: 14px;
    text-align: center;
    margin-bottom: 20px;
    line-height: 1.5;
}

.modal-box input {
    width: 100%;
    padding: 16px 18px;
    border-radius: 10px;
    border: 1px solid var(--border);
    font-size: 16px;
    background: var(--input-bg);
    color: var(--text-dark);
    margin-bottom: 20px;
    transition: all 0.3s ease;
    text-align: center;
    letter-spacing: 8px;
    font-weight: 600;
    font-size: 20px;
    box-shadow: inset 0 2px 4px rgba(111, 78, 55, 0.05);
}

.modal-box input:focus {
    outline: none;
    border-color: var(--accent-brown);
    box-shadow: 
        0 0 0 3px rgba(150, 114, 89, 0.2),
        inset 0 2px 4px rgba(111, 78, 55, 0.05);
    background-color: var(--white);
}

.modal-actions {
    margin-bottom: 15px;
}

/* OTP Resend Link */
.otp-resend {
    text-align: center;
    margin-top: 15px;
    font-size: 14px;
    color: var(--accent-brown);
}

.otp-resend a {
    color: var(--primary-brown);
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
}

.otp-resend a:hover {
    text-decoration: underline;
    color: var(--dark-brown);
}

/* OTP Timer */
.otp-timer {
    text-align: center;
    margin-top: 10px;
    font-size: 14px;
    color: var(--accent-brown);
    font-weight: 600;
}

/* ==============================
   RESPONSIVE DESIGN
============================== */

/* Tablet */
@media (max-width: 768px) {
    .signup-container {
        max-width: 400px;
        padding: 30px 25px;
        margin: 20px 15px;
    }
    
    .signup-container::before {
        top: -50px;
        width: 100px;
        height: 80px;
    }
    
    .page-title h2 {
        font-size: 26px;
    }
    
    .modal-box {
        padding: 25px;
    }
}

/* Mobile */
@media (max-width: 480px) {
    body {
        padding: 15px;
    }
    
    .signup-container {
        padding: 25px 20px;
        margin: 15px 10px;
    }
    
    .signup-container::before {
        top: -40px;
        width: 80px;
        height: 70px;
    }
    
    .page-title h2 {
        font-size: 24px;
    }
    
    .page-title p {
        font-size: 14px;
    }
    
    .signup-form input {
        padding: 14px 16px;
        font-size: 15px;
    }
    
    .btn {
        padding: 14px;
        font-size: 15px;
    }
    
    .modal-box {
        padding: 22px 20px;
    }
    
    .modal-header h3 {
        font-size: 20px;
    }
    
    .modal-box input {
        padding: 14px 16px;
        font-size: 18px;
        letter-spacing: 6px;
    }
}

/* Small Mobile */
@media (max-width: 360px) {
    .signup-container {
        padding: 22px 18px;
    }
    
    .page-title h2 {
        font-size: 22px;
    }
    
    .signup-form input {
        padding: 12px 14px;
        font-size: 14px;
    }
    
    .btn {
        padding: 13px;
        font-size: 14px;
    }
    
    .toggle-password {
        right: 12px;
    }
    
    .toggle-password svg {
        width: 20px;
        height: 20px;
    }
    
    .signin-link {
        font-size: 14px;
    }
}

/* Accessibility */
@media (prefers-reduced-motion: reduce) {
    .btn,
    .signup-form input,
    .modal-box,
    .toggle-password,
    .modal-close {
        transition: none;
        animation: none;
    }
    
    .btn::after,
    .signup-container::after {
        display: none;
    }
    
    .signup-container::after {
        animation: none;
    }
}

/* Focus visible for keyboard navigation */
.signup-form input:focus-visible,
.btn:focus-visible,
.toggle-password:focus-visible,
.modal-close:focus-visible,
.signin-link a:focus-visible {
    outline: 2px solid var(--accent-brown);
    outline-offset: 2px;
}

/* High contrast mode */
@media (prefers-contrast: high) {
    :root {
        --border: #38220F;
        --shadow: rgba(56, 34, 15, 0.3);
    }
    
    .signup-container,
    .modal-box {
        border: 2px solid var(--border);
    }
    
    .btn {
        border: 2px solid currentColor;
    }
}

