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

body {
    font-family: 'Tahoma', 'Segoe UI', sans-serif;
    font-size: 13px;
    background: #3a6ea5;
    min-height: 100vh;
    overflow: hidden;
    position: relative;
}

/* === XP DESKTOP BACKGROUND === */
.xp-desktop {
    position: fixed;
    inset: 0;
    background:
        radial-gradient(ellipse 120% 80% at 50% 60%, #5a9fd4 0%, #3a6ea5 40%, #1a4080 100%);
    z-index: 0;
}

/* Bliss-style hills */
.xp-desktop::before {
    content: '';
    position: absolute;
    bottom: 0; left: 0; right: 0;
    height: 45%;
    background:
        radial-gradient(ellipse 160% 120% at 50% 110%,
            #5cb85c 0%, #4cae4c 30%, #3d8b3d 60%, transparent 80%);
    border-radius: 100% 100% 0 0 / 60% 60% 0 0;
}
.xp-desktop::after {
    content: '';
    position: absolute;
    bottom: 0; left: -10%; right: -10%;
    height: 35%;
    background:
        radial-gradient(ellipse 120% 100% at 50% 110%,
            #6dc96d 0%, #5aba5a 40%, transparent 70%);
    border-radius: 100% 100% 0 0 / 50% 50% 0 0;
}

/* Clouds */
.cloud {
    position: absolute;
    background: rgba(255,255,255,0.85);
    border-radius: 50px;
    filter: blur(2px);
    animation: cloudDrift linear infinite;
}
.cloud::before, .cloud::after {
    content: '';
    position: absolute;
    background: rgba(255,255,255,0.9);
    border-radius: 50%;
}
.cloud-1 { width: 120px; height: 36px; top: 12%; left: -150px; animation-duration: 45s; animation-delay: -10s; }
.cloud-1::before { width: 60px; height: 50px; top: -25px; left: 20px; }
.cloud-1::after  { width: 45px; height: 40px; top: -18px; left: 55px; }
.cloud-2 { width: 90px; height: 28px; top: 20%; left: -120px; animation-duration: 60s; animation-delay: -25s; opacity:0.7; }
.cloud-2::before { width: 45px; height: 38px; top: -20px; left: 15px; }
.cloud-2::after  { width: 35px; height: 30px; top: -14px; left: 42px; }
.cloud-3 { width: 150px; height: 40px; top: 8%; left: -200px; animation-duration: 55s; animation-delay: -5s; opacity:0.6; }
.cloud-3::before { width: 70px; height: 55px; top: -28px; left: 25px; }
.cloud-3::after  { width: 55px; height: 45px; top: -22px; left: 68px; }

@keyframes cloudDrift {
    from { transform: translateX(0); }
    to   { transform: translateX(calc(100vw + 300px)); }
}

/* === XP TASKBAR === */
.xp-taskbar {
    position: fixed;
    bottom: 0; left: 0; right: 0;
    height: 38px;
    background: linear-gradient(to bottom, #1f5ba8 0%, #3a7fd4 8%, #2a6bc4 45%, #1a57b8 46%, #1f5cc0 100%);
    border-top: 2px solid #4a8fe0;
    z-index: 1000;
    display: flex;
    align-items: center;
    padding: 0 4px;
    box-shadow: 0 -1px 0 #0a3070;
}

.xp-start-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 3px 12px 3px 8px;
    background: linear-gradient(to bottom, #61a534 0%, #5ea030 40%, #4d8a26 41%, #4a8522 100%);
    border: 1px solid #2a6010;
    border-radius: 12px;
    color: white;
    font-family: 'Tahoma', sans-serif;
    font-size: 13px;
    font-weight: bold;
    cursor: pointer;
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.3), 0 1px 3px rgba(0,0,0,0.4);
    text-shadow: 1px 1px 1px rgba(0,0,0,0.5);
    height: 30px;
}
.xp-start-btn:hover {
    background: linear-gradient(to bottom, #72b645 0%, #6eb240 40%, #5d9a36 41%, #5a9532 100%);
}
.start-orb {
    width: 20px; height: 20px;
    background: radial-gradient(circle at 40% 35%, #ff6060, #cc0000);
    border-radius: 50%;
    box-shadow: 0 0 4px rgba(0,0,0,0.4);
    display: flex; align-items: center; justify-content: center;
    font-size: 10px;
}

.taskbar-time {
    margin-left: auto;
    background: linear-gradient(to bottom, #1050a0 0%, #1a5ab0 50%, #1050a0 100%);
    border: 1px solid #0a3070;
    border-radius: 2px;
    padding: 2px 10px;
    color: white;
    font-size: 12px;
    font-family: 'Tahoma', sans-serif;
    display: flex;
    flex-direction: column;
    align-items: center;
    line-height: 1.3;
    box-shadow: inset 1px 1px 0 rgba(255,255,255,0.1);
}

/* === MAIN LAYOUT === */
.page-wrapper {
    position: relative;
    z-index: 10;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 20px 20px 60px;
}

/* === XP WINDOW (main dialog) === */
.xp-window {
    width: 100%;
    max-width: 780px;
    background: #ece9d8;
    border: 1px solid #0053a0;
    border-radius: 8px 8px 4px 4px;
    box-shadow:
        0 0 0 1px #003380,
        4px 4px 20px rgba(0,0,0,0.5),
        inset 0 0 0 1px rgba(255,255,255,0.8);
    overflow: hidden;
    animation: windowOpen 0.35s cubic-bezier(0.2, 0.8, 0.4, 1);
}

@keyframes windowOpen {
    from { transform: scale(0.92) translateY(10px); opacity: 0; }
    to   { transform: scale(1) translateY(0); opacity: 1; }
}

/* XP title bar */
.xp-titlebar {
    background: linear-gradient(to bottom,
        #2579d4 0%, #1263b8 5%, #0f5ab0 45%,
        #0a52a8 46%, #0d57ae 100%);
    padding: 4px 8px;
    display: flex;
    align-items: center;
    gap: 8px;
    border-bottom: 1px solid #003380;
    user-select: none;
}
.titlebar-icon {
    width: 18px; height: 18px;
    display: flex; align-items: center; justify-content: center;
}
.titlebar-icon img {
    width: 18px; height: 18px; object-fit: contain;
}
.titlebar-title {
    color: white;
    font-size: 12px;
    font-weight: bold;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.6);
    flex: 1;
}
.titlebar-btns {
    display: flex; gap: 2px;
}
.tb-btn {
    width: 21px; height: 21px;
    border-radius: 3px;
    border: 1px solid;
    font-size: 11px;
    display: flex; align-items: center; justify-content: center;
    cursor: pointer;
    font-family: 'Tahoma', sans-serif;
    font-weight: bold;
    color: black;
}
.tb-btn.minimize {
    background: linear-gradient(to bottom, #f0f0e0, #d8d8c0);
    border-color: #808060;
}
.tb-btn.maximize {
    background: linear-gradient(to bottom, #f0f0e0, #d8d8c0);
    border-color: #808060;
}
.tb-btn.close {
    background: linear-gradient(to bottom, #e07060, #c04030);
    border-color: #802010;
    color: white;
    text-shadow: 1px 1px 1px rgba(0,0,0,0.4);
}
.tb-btn.close:hover {
    background: linear-gradient(to bottom, #f08070, #d05040);
}

/* XP window body */
.xp-body {
    display: flex;
    min-height: 420px;
}

/* LEFT PANEL - blue brand panel */
.xp-left-panel {
    width: 220px;
    flex-shrink: 0;
    background: linear-gradient(to bottom,
        #1f5ba8 0%, #1a4e96 30%,
        #163d7a 70%, #0f2d5c 100%);
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 30px 20px 20px;
    position: relative;
    overflow: hidden;
}
.xp-left-panel::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 3px;
    background: linear-gradient(to right, #4a90d8, #7ab8f0, #4a90d8);
}
.xp-left-panel::after {
    content: '';
    position: absolute;
    bottom: 60px;
    left: -40px;
    width: 160px; height: 160px;
    background: rgba(255,255,255,0.03);
    border-radius: 50%;
}

.brand-logo-area {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 14px;
    margin-bottom: 30px;
}
.brand-logo-area img {
    width: 60px; height: 60px;
    object-fit: contain;
    filter: drop-shadow(0 2px 8px rgba(0,0,0,0.4));
}
.brand-name {
    color: white;
    font-size: 20px;
    font-weight: bold;
    text-shadow: 0 1px 3px rgba(0,0,0,0.5);
    letter-spacing: 1px;
}
.brand-tagline {
    color: #a8c8f0;
    font-size: 10px;
    text-align: center;
    line-height: 1.5;
}

.xp-divider-h {
    width: 80%;
    height: 1px;
    background: linear-gradient(to right, transparent, rgba(255,255,255,0.3), transparent);
    margin: 10px 0;
}

.panel-info-items {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 10px;
}
.panel-info-item {
    display: flex;
    align-items: center;
    gap: 10px;
    color: #c0d8f0;
    font-size: 11px;
}
.panel-info-item i {
    width: 16px;
    color: #70a8e0;
}

.xp-left-footer {
    margin-top: auto;
    color: #6080a8;
    font-size: 10px;
    text-align: center;
}

/* RIGHT PANEL - form area */
.xp-right-panel {
    flex: 1;
    padding: 24px 32px;
    display: flex;
    flex-direction: column;
    background: #ece9d8;
}

.form-heading {
    font-size: 16px;
    font-weight: bold;
    color: #003380;
    margin-bottom: 4px;
    display: flex;
    align-items: center;
    gap: 8px;
}
.form-heading i {
    color: #0066cc;
}
.form-subheading {
    color: #666;
    font-size: 11px;
    margin-bottom: 20px;
}

/* XP horizontal rule separator */
.xp-sep {
    border: none;
    border-top: 1px solid #c0bdb0;
    border-bottom: 1px solid #ffffff;
    margin: 0 0 20px 0;
}

/* Notifications */
.notif-area {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 14px;
}
.login-notif {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 8px 12px;
    border: 1px solid;
    border-radius: 3px;
    font-size: 12px;
}
.login-notif i { margin-top: 1px; flex-shrink: 0; }
.notif-content strong { display: block; font-weight: bold; font-size: 12px; }
.notif-content p { margin: 2px 0 0; font-size: 11px; opacity: 0.85; }
.notif-info    { background: #e8f4fd; border-color: #5b9bd5; color: #1a4a80; }
.notif-success { background: #e8f8e8; border-color: #70b070; color: #1a5020; }
.notif-warning { background: #fff8e0; border-color: #d4a020; color: #704010; }
.notif-danger  { background: #fde8e8; border-color: #c05050; color: #801010; }

/* Alert boxes */
.alert {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    border: 1px solid;
    border-radius: 3px;
    margin-bottom: 14px;
    font-size: 12px;
}
.alert-error {
    background: #fde8e8;
    border-color: #c04040;
    color: #801010;
}
.alert-success {
    background: #e8f8e8;
    border-color: #50a050;
    color: #105020;
}
.alert i { flex-shrink: 0; }

/* XP form fields */
.xp-form-row {
    margin-bottom: 14px;
}
.xp-label {
    display: block;
    font-size: 12px;
    font-weight: bold;
    color: #222;
    margin-bottom: 4px;
}
.xp-input-wrap {
    position: relative;
}
.xp-input {
    width: 100%;
    padding: 5px 8px 5px 30px;
    font-family: 'Tahoma', sans-serif;
    font-size: 13px;
    background: white;
    border: 2px solid;
    border-color: #7f9db9 #f0f0f0 #f0f0f0 #7f9db9;
    border-radius: 0;
    outline: none;
    color: #000;
    box-shadow: inset 1px 1px 3px rgba(0,0,0,0.12);
    transition: border-color 0.15s;
}
.xp-input:focus {
    border-color: #0066cc #ccc #ccc #0066cc;
    box-shadow: inset 1px 1px 3px rgba(0,0,0,0.12), 0 0 0 1px #6090d0;
}
.xp-input-icon {
    position: absolute;
    left: 8px;
    top: 50%;
    transform: translateY(-50%);
    color: #6080a8;
    font-size: 12px;
    pointer-events: none;
}
.pw-toggle {
    position: absolute;
    right: 6px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    cursor: pointer;
    color: #6080a8;
    font-size: 12px;
    padding: 2px;
}
.pw-toggle:hover { color: #0044aa; }

/* Remember me & forgot */
.xp-form-options {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 20px;
}
.xp-checkbox-label {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    cursor: pointer;
    color: #333;
}
.xp-checkbox-label input[type=checkbox] {
    width: 13px; height: 13px;
    border: 1px solid #7f9db9;
    accent-color: #0053a0;
    cursor: pointer;
}
.xp-forgot {
    font-size: 12px;
    color: #0044cc;
    text-decoration: none;
}
.xp-forgot:hover { text-decoration: underline; }

/* XP-style button */
.xp-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 6px 20px;
    font-family: 'Tahoma', sans-serif;
    font-size: 13px;
    font-weight: bold;
    background: linear-gradient(to bottom,
        #f0f0e0 0%, #e8e4d0 48%, #d8d4c0 49%, #ccc8b4 100%);
    border: 1px solid #888870;
    border-radius: 3px;
    color: #000;
    cursor: pointer;
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.8), 1px 1px 2px rgba(0,0,0,0.2);
    min-width: 90px;
}
.xp-btn:hover {
    background: linear-gradient(to bottom,
        #dce8f8 0%, #ccd8f0 48%, #b8c8e8 49%, #a8b8d8 100%);
    border-color: #5070a8;
}
.xp-btn:active {
    background: linear-gradient(to bottom,
        #c0cce0 0%, #b0bcd0 100%);
    box-shadow: inset 1px 1px 3px rgba(0,0,0,0.3);
}
.xp-btn.primary {
    background: linear-gradient(to bottom,
        #5090e0 0%, #2870d0 48%, #1060c8 49%, #0858c0 100%);
    border-color: #003880;
    color: white;
    text-shadow: 0 1px 1px rgba(0,0,0,0.4);
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.3), 1px 1px 3px rgba(0,0,0,0.3);
}
.xp-btn.primary:hover {
    background: linear-gradient(to bottom,
        #60a0f0 0%, #3880e0 48%, #2070d8 49%, #1868d0 100%);
}
.xp-btn.primary:active {
    background: linear-gradient(to bottom,
        #1858b8 0%, #0848a8 100%);
}
.xp-btn.primary.loading {
    opacity: 0.75;
    cursor: not-allowed;
}
.xp-btn-row {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
}

/* Bottom footer of dialog */
.xp-dialog-footer {
    background: #d4d0c0;
    border-top: 1px solid #c0bdb0;
    padding: 6px 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.footer-links {
    display: flex;
    gap: 16px;
}
.footer-links a {
    font-size: 11px;
    color: #0044cc;
    text-decoration: none;
}
.footer-links a:hover { text-decoration: underline; }
.footer-copy {
    font-size: 10px;
    color: #888;
}

/* XP security badge */
.xp-security-badge {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 6px 10px;
    background: #f0efe4;
    border: 1px solid #c8c4b0;
    border-radius: 3px;
    margin-top: 14px;
    font-size: 11px;
    color: #555;
}
.xp-security-badge i { color: #d4a820; font-size: 13px; }

/* Responsive */
@media (max-width: 600px) {
    .xp-window { max-width: 100%; border-radius: 6px 6px 3px 3px; }
    .xp-left-panel { width: 160px; padding: 20px 12px; }
    .xp-right-panel { padding: 16px 16px; }
    .panel-info-items { display: none; }
}
@media (max-width: 480px) {
    .xp-body { flex-direction: column; }
    .xp-left-panel { width: 100%; padding: 16px; flex-direction: row; justify-content: center; gap: 16px; }
    .brand-logo-area { flex-direction: row; margin-bottom: 0; }
    .xp-left-footer { display: none; }
    .xp-divider-h { display: none; }
}
