* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    background-color: #e5e5f7 !important;
    background-image: radial-gradient(#b0b0b0 10%, transparent 10%),
                    radial-gradient(#b0b0b0 10%, transparent 10%);
    background-size: 100px 100px;
    background-position: 0 0, 50px 50px;
    color: #222;
}

/* Remove animated backgrounds, particles, waves */
.animated-bg,
.particles,
.wave-container,
.wave,
.particle {
    display: none !important;
}

.auth-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: #f7f7fa;
}

.auth-card {
    background: #fff;
    border-radius: 0 !important;
    padding: 40px 32px;
    box-shadow: 0 4px 24px rgba(40,44,52,0.08);
    border: 1px solid #e2e2e2;
    max-width: 520px;
    width: 100%;
    animation: slideIn 0.6s ease-out;
}

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

.auth-card h1 {
    margin: 0 0 35px 0;
    font-size: 32px;
    font-weight: 700;
    color: #2d3748;
    text-align: center;
    background: none;
    -webkit-text-fill-color: unset;
    animation: fadeIn 0.8s ease-out 0.2s both;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.form-group {
    margin-bottom: 25px;
    position: relative;
    animation: fadeIn 0.8s ease-out 0.3s both;
}

.form-group:nth-child(2) {
    animation-delay: 0.4s;
}

.form-group:nth-child(3) {
    animation-delay: 0.5s;
}

.form-group:nth-child(4) {
    animation-delay: 0.6s;
}

.form-group label {
    display: block;
    margin-bottom: 10px;
    font-weight: 600;
    color: #59433B;
    font-size: 14px;
    transition: color 0.3s ease;
}

.form-group input {
    width: 100%;
    padding: 14px 16px;
    border: 2px solid #e2e2e2;
    border-radius: 12px;
    font-size: 15px;
    transition: all 0.3s ease;
    background: #fff;
    position: relative;
    color: #222;
}

.form-group input::placeholder {
    color: rgba(89, 67, 59, 0.5);
}

.form-group input:focus {
    outline: none;
    border-color: #2d3748;
    box-shadow: 0 0 0 2px #2d374822;
    transform: translateY(-2px);
}

.form-group input:focus + label {
    color: #03658C;
}

.form-group small {
    display: block;
    margin-top: 6px;
    font-size: 12px;
    color: #59433B;
    opacity: 0.7;
    animation: fadeIn 0.5s ease-out;
}

/* Floating Label Effect */
.floating-input {
    position: relative;
}

.floating-input input {
    padding-top: 20px;
    padding-bottom: 8px;
}

.floating-input label {
    position: absolute;
    left: 16px;
    top: 14px;
    transition: all 0.3s ease;
    pointer-events: none;
    color: #59433B;
    opacity: 0.7;
}

.floating-input input:focus + label,
.floating-input input:not(:placeholder-shown) + label {
    top: 4px;
    font-size: 11px;
    color: #03658C;
}

.error-message,
.success-message {
    font-size: 14px;
    margin: 20px 0;
    padding: 12px 16px;
    border-radius: 10px;
    display: none;
    animation: shake 0.5s ease-out;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    10%, 30%, 50%, 70%, 90% { transform: translateX(-5px); }
    20%, 40%, 60%, 80% { transform: translateX(5px); }
}

.error-message {
    color: #b71c1c;
    background: #fbeaea;
    border-left: 4px solid #b71c1c;
    border-radius: 0 !important;
}

.error-message:not(:empty) {
    display: block;
}

.success-message {
    color: #2d3748;
    background: #eafbf2;
    border-left: 4px solid #2d3748;
    border-radius: 0 !important;
}

.success-message:not(:empty) {
    display: block;
}

.auth-btn {
    width: 100%;
    padding: 16px;
    background: #2d3748;
    color: #fff;
    border-radius: 0 !important;
    font-weight: 600;
    box-shadow: none;
    border: none;
    transition: background 0.2s;
    position: relative;
    overflow: hidden;
    animation: fadeIn 0.8s ease-out 0.7s both;
}

.auth-btn:hover {
    background: #1a202c;
}

.auth-btn:active {
    transform: translateY(-1px);
    box-shadow: 0 5px 15px rgba(3, 101, 140, 0.4);
}

.auth-btn:disabled {
    background: #59433B;
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

/* Loading Spinner */
.auth-btn.loading::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    top: 50%;
    left: 50%;
    margin-left: -10px;
    margin-top: -10px;
    border: 3px solid rgba(213, 229, 242, 0.3);
    border-top-color: #D5E5F2;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.auth-link {
    text-align: center;
    margin-top: 25px;
    font-size: 14px;
    color: #59433B;
    animation: fadeIn 0.8s ease-out 0.8s both;
}

.auth-link a {
    color: #03658C;
    text-decoration: none;
    font-weight: 600;
    position: relative;
    transition: color 0.3s ease;
}

.auth-link a::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(135deg, #03658C 0%, #03658C 100%);
    transition: width 0.3s ease;
}

.auth-link a:hover {
    color: #03658C;
}

.auth-link a:hover::after {
    width: 100%;
}

/* Password Strength Indicator */
.password-strength {
    margin-top: 8px;
    height: 4px;
    background: #D9D6A9;
    border-radius: 2px;
    overflow: hidden;
    display: none;
}

.password-strength.show {
    display: block;
}

.password-strength-bar {
    height: 100%;
    width: 0;
    transition: all 0.3s ease;
    border-radius: 2px;
}

.password-strength-bar.weak {
    width: 33%;
    background: #03658C;
}

.password-strength-bar.medium {
    width: 66%;
    background: #D9D6A9;
}

.password-strength-bar.strong {
    width: 100%;
    background: #03658C;
}

/* Responsive Design */
@media (max-width: 480px) {
    .auth-card {
        padding: 40px 30px;
    }
    
    .auth-card h1 {
        font-size: 26px;
    }
    
    .particle {
        display: none;
    }
}

/* Custom Checkbox/Radio Styling */
.checkbox-group {
    display: flex;
    align-items: center;
    margin: 20px 0;
}

.checkbox-group input[type="checkbox"] {
    width: 20px;
    height: 20px;
    margin-right: 10px;
    cursor: pointer;
    accent-color: #03658C;
}

.checkbox-group label {
    margin: 0;
    cursor: pointer;
    user-select: none;
    color: #59433B;
}

/* Make all edges sharp */
*,
*::before,
*::after {
  border-radius: 0 !important;
}

/* Ensure common UI components are square */
.auth-card,
.auth-btn,
.form-group input,
.form-group select,
.form-group textarea,
.condition-card,
.exercise-tile,
.dashboard-tile,
.particle,
.user-header,
.logout-btn {
  border-radius: 0 !important;
}