* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
}

body {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 50%, #f093fb 100%);
    background-size: 400% 400%;
    animation: gradientBG 15s ease infinite;
    padding: 20px;
    position: relative;
    overflow: hidden;
}

@keyframes gradientBG {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* Floating shapes background */
body::before,
body::after {
    content: '';
    position: absolute;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    animation: float 8s ease-in-out infinite;
}

body::before {
    width: 300px;
    height: 300px;
    top: -100px;
    left: -100px;
}

body::after {
    width: 400px;
    height: 400px;
    bottom: -150px;
    right: -150px;
    animation-delay: 2s;
}

@keyframes float {
    0%, 100% { transform: translateY(0) scale(1); }
    50% { transform: translateY(-30px) scale(1.05); }
}

/* Login Card */
.login-container {
    position: relative;
    z-index: 10;
    width: 100%;
    max-width: 420px;
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.25);
    border-radius: 24px;
    padding: 48px 40px;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.2);
    animation: slideUp 0.6s ease-out;
}

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

/* Logo */
.logo-wrapper {
    display: flex;
    justify-content: center;
    margin-bottom: 24px;
}

.logo-icon {
    width: 72px;
    height: 72px;
    background: linear-gradient(135deg, #667eea, #764ba2);
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 10px 25px rgba(102, 126, 234, 0.5);
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { box-shadow: 0 10px 25px rgba(102, 126, 234, 0.5); }
    50% { box-shadow: 0 10px 35px rgba(102, 126, 234, 0.8); }
}

.logo-icon svg {
    width: 36px;
    height: 36px;
    fill: white;
}

/* Header */
.login-header {
    text-align: center;
    margin-bottom: 32px;
}

.login-header h1 {
    color: white;
    font-size: 26px;
    font-weight: 700;
    margin-bottom: 8px;
    letter-spacing: -0.5px;
}

.login-header p {
    color: rgba(255, 255, 255, 0.8);
    font-size: 14px;
}

/* Form */
.form-group {
    margin-bottom: 20px;
    position: relative;
}

.form-group label {
    display: block;
    color: rgba(255, 255, 255, 0.9);
    font-size: 13px;
    font-weight: 500;
    margin-bottom: 8px;
    padding-left: 4px;
}

.input-wrapper {
    position: relative;
}

.input-icon {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    width: 18px;
    height: 18px;
    fill: rgba(255, 255, 255, 0.6);
    transition: fill 0.3s;
}

.form-control {
    width: 100%;
    padding: 14px 16px 14px 46px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 12px;
    color: white;
    font-size: 14px;
    outline: none;
    transition: all 0.3s ease;
}

.form-control::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.form-control:focus {
    background: rgba(255, 255, 255, 0.18);
    border-color: rgba(255, 255, 255, 0.6);
    box-shadow: 0 0 0 4px rgba(255, 255, 255, 0.1);
}

.form-control:focus ~ .input-icon {
    fill: white;
}

/* Toggle Password */
.toggle-password {
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
    display: flex;
    align-items: center;
}

.toggle-password svg {
    width: 18px;
    height: 18px;
    fill: rgba(255, 255, 255, 0.6);
    transition: fill 0.3s;
}

.toggle-password:hover svg {
    fill: white;
}

/* Checkbox & Forgot */
.form-options {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 24px;
    font-size: 13px;
}

.remember-me {
    display: flex;
    align-items: center;
    gap: 8px;
    color: rgba(255, 255, 255, 0.85);
    cursor: pointer;
    user-select: none;
}

.remember-me input[type="checkbox"] {
    width: 16px;
    height: 16px;
    accent-color: #667eea;
    cursor: pointer;
}

.forgot-link {
    color: rgba(255, 255, 255, 0.85);
    text-decoration: none;
    transition: color 0.3s;
}

.forgot-link:hover {
    color: white;
    text-decoration: underline;
}

/* Button */
.btn-login {
    width: 100%;
    padding: 15px;
    background: linear-gradient(135deg, #667eea, #764ba2);
    border: none;
    border-radius: 12px;
    color: white;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 8px 20px rgba(102, 126, 234, 0.4);
    position: relative;
    overflow: hidden;
    letter-spacing: 0.3px;
}

.btn-login:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 28px rgba(102, 126, 234, 0.6);
}

.btn-login:active {
    transform: translateY(0);
}

.btn-login::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    transition: left 0.5s;
}

.btn-login:hover::before {
    left: 100%;
}

/* Alert */
.alert {
    padding: 12px 16px;
    border-radius: 10px;
    margin-bottom: 20px;
    font-size: 13px;
    display: flex;
    align-items: center;
    gap: 10px;
    animation: shake 0.4s ease;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-5px); }
    75% { transform: translateX(5px); }
}

.alert-error {
    background: rgba(239, 68, 68, 0.2);
    border: 1px solid rgba(239, 68, 68, 0.4);
    color: #fecaca;
}

.alert-success {
    background: rgba(34, 197, 94, 0.2);
    border: 1px solid rgba(34, 197, 94, 0.4);
    color: #bbf7d0;
}

/* Footer */
.login-footer {
    text-align: center;
    margin-top: 28px;
    color: rgba(255, 255, 255, 0.6);
    font-size: 12px;
}

/* Responsive */
@media (max-width: 480px) {
    .login-container {
        padding: 36px 24px;
        border-radius: 20px;
    }
    .login-header h1 {
        font-size: 22px;
    }
}

/* ============================================
   WEBSITE PANEL (muncul saat navbar Website diklik)
   ============================================ */
.website-panel {
    background: white;
    border-radius: 16px;
    padding: 20px 24px;
    margin-bottom: 20px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.06);
    border: 1px solid rgba(102,126,234,0.1);
    animation: slideDown 0.35s ease;
}

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

.website-panel-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    margin-bottom: 16px;
    flex-wrap: wrap;
}

.website-panel-title {
    display: flex;
    align-items: center;
    gap: 12px;
}

.website-panel-title .panel-icon {
    width: 40px; height: 40px;
    background: linear-gradient(135deg, #667eea, #764ba2);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 12px rgba(102,126,234,0.3);
}

.website-panel-title .panel-icon svg {
    width: 20px; height: 20px;
    fill: white;
}

.website-panel-title h3 {
    font-size: 15px;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 2px;
}

.website-panel-title p {
    font-size: 12px;
    color: #94a3b8;
}

.btn-tambah-website {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 10px 18px;
    background: linear-gradient(135deg, #667eea, #764ba2);
    border: none;
    border-radius: 10px;
    color: white;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.25s ease;
    box-shadow: 0 6px 18px rgba(102,126,234,0.35);
    font-family: inherit;
}

.btn-tambah-website:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(102,126,234,0.5);
}

.btn-tambah-website svg {
    width: 16px; height: 16px;
    fill: white;
}

/* IP Info */
.ip-info {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 14px;
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    border-radius: 10px;
    font-size: 12px;
    color: #16a34a;
    margin-bottom: 16px;
    flex-wrap: wrap;
}

.ip-info svg {
    width: 16px; height: 16px;
    fill: #16a34a;
    flex-shrink: 0;
}

.ip-info strong {
    font-family: 'Courier New', monospace;
    background: white;
    padding: 2px 8px;
    border-radius: 6px;
    color: #15803d;
}

.ip-info .ip-hint { color: #65a30d; }

/* Website List */
.website-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.website-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 14px;
    background: #f8fafc;
    border: 1.5px solid #e2e8f0;
    border-radius: 10px;
    transition: all 0.2s ease;
}

.website-item:hover {
    border-color: #c7d2fe;
    background: #eef2ff;
}

.website-item-icon {
    width: 36px; height: 36px;
    border-radius: 9px;
    background: linear-gradient(135deg, #667eea, #764ba2);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.website-item-icon svg {
    width: 18px; height: 18px;
    fill: white;
}

.website-item-info { flex: 1; min-width: 0; }

.website-item-name {
    font-size: 13px;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 2px;
}

.website-item-url {
    font-size: 11px;
    color: #94a3b8;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.status-badge {
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.status-badge.pending     { background: #fef3c7; color: #b45309; }
.status-badge.success     { background: #dcfce7; color: #15803d; }
.status-badge.failed      { background: #fee2e2; color: #b91c1c; }
.status-badge.whitelisted { background: #dbeafe; color: #1d4ed8; }

.empty-state {
    text-align: center;
    padding: 24px;
    color: #94a3b8;
    font-size: 13px;
}

/* ============================================
   MODAL
   ============================================ */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.6);
    backdrop-filter: blur(4px);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 999;
    padding: 20px;
    animation: fadeIn 0.2s ease;
}

.modal-overlay.show { display: flex; }

@keyframes fadeIn {
    from { opacity: 0; }
    to   { opacity: 1; }
}

.modal-box {
    background: white;
    border-radius: 20px;
    width: 100%;
    max-width: 560px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 25px 60px rgba(0,0,0,0.3);
    animation: modalSlide 0.3s ease;
}

@keyframes modalSlide {
    from { opacity: 0; transform: translateY(20px) scale(0.97); }
    to   { opacity: 1; transform: translateY(0) scale(1); }
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 24px;
    border-bottom: 1px solid #f1f5f9;
}

.modal-title {
    display: flex;
    align-items: center;
    gap: 12px;
}

.modal-icon {
    width: 42px; height: 42px;
    background: linear-gradient(135deg, #667eea, #764ba2);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 6px 15px rgba(102,126,234,0.35);
}

.modal-icon svg { width: 22px; height: 22px; fill: white; }

.modal-title h3 {
    font-size: 16px;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 2px;
}

.modal-title p {
    font-size: 12px;
    color: #94a3b8;
}

.modal-close {
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
    border-radius: 8px;
    transition: 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-close:hover { background: #f1f5f9; }

.modal-close svg {
    width: 20px; height: 20px;
    fill: #64748b;
}

.modal-body {
    padding: 20px 24px;
}

.form-row {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 12px;
}

.form-group {
    margin-bottom: 14px;
}

.form-group label {
    display: block;
    font-size: 12px;
    font-weight: 600;
    color: #475569;
    margin-bottom: 6px;
}

.form-group .required { color: #ef4444; }
.form-group .optional { color: #94a3b8; font-weight: 400; font-size: 11px; }

.form-control {
    width: 100%;
    padding: 11px 14px;
    background: #f8fafc;
    border: 1.5px solid #e2e8f0;
    border-radius: 10px;
    font-size: 13px;
    color: #1e293b;
    outline: none;
    transition: 0.25s;
    font-family: inherit;
}

.form-control:focus {
    border-color: #667eea;
    background: white;
    box-shadow: 0 0 0 4px rgba(102,126,234,0.1);
}

.form-control::placeholder { color: #cbd5e1; }

/* Password toggle */
.input-password-wrap { position: relative; }

.input-password-wrap .form-control { padding-right: 44px; }

.toggle-eye {
    position: absolute;
    right: 8px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    cursor: pointer;
    padding: 6px;
    border-radius: 6px;
    display: flex;
    align-items: center;
}

.toggle-eye:hover { background: #f1f5f9; }

.toggle-eye svg {
    width: 16px; height: 16px;
    fill: #94a3b8;
}

.form-divider {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 6px 0 14px;
    font-size: 11px;
    font-weight: 700;
    color: #667eea;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.form-divider::before,
.form-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: linear-gradient(90deg, transparent, #e0e7ff, transparent);
}

.whitelist-note {
    display: flex;
    gap: 10px;
    padding: 12px 14px;
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    border-radius: 10px;
    font-size: 12px;
    color: #166534;
    margin-top: 8px;
}

.whitelist-note svg {
    width: 18px; height: 18px;
    fill: #16a34a;
    flex-shrink: 0;
    margin-top: 1px;
}

.whitelist-note strong {
    display: block;
    margin-bottom: 3px;
    font-size: 12px;
}

.whitelist-note p { line-height: 1.5; font-size: 11px; }

.whitelist-note code {
    background: white;
    padding: 1px 6px;
    border-radius: 4px;
    font-family: 'Courier New', monospace;
    color: #15803d;
    font-size: 11px;
}

.modal-alert {
    padding: 10px 14px;
    border-radius: 10px;
    font-size: 12px;
    margin-top: 12px;
}

.modal-alert.error {
    background: #fef2f2;
    border: 1px solid #fecaca;
    color: #dc2626;
}

.modal-alert.success {
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    color: #16a34a;
}

.modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    padding: 16px 24px;
    border-top: 1px solid #f1f5f9;
    background: #fafbfc;
    border-bottom-left-radius: 20px;
    border-bottom-right-radius: 20px;
}

.btn-cancel {
    padding: 10px 20px;
    background: white;
    border: 1.5px solid #e2e8f0;
    border-radius: 10px;
    color: #475569;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: 0.25s;
    font-family: inherit;
}

.btn-cancel:hover { background: #f1f5f9; border-color: #cbd5e1; }

.btn-submit {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 10px 22px;
    background: linear-gradient(135deg, #667eea, #764ba2);
    border: none;
    border-radius: 10px;
    color: white;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: 0.25s;
    box-shadow: 0 6px 18px rgba(102,126,234,0.35);
    font-family: inherit;
}

.btn-submit:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(102,126,234,0.5);
}

.btn-submit:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.btn-submit svg { width: 15px; height: 15px; fill: white; }

/* Responsive */
@media (max-width: 640px) {
    .form-row { grid-template-columns: 1fr; }
    .modal-box { max-height: 95vh; }
    .website-panel-header { flex-direction: column; align-items: stretch; }
    .btn-tambah-website { justify-content: center; }
}