:root {
    --bg-color: #0d1117;
    --card-bg: #161b22;
    --card-border: #30363d;
    --text-primary: #e6edf3;
    --text-secondary: #848d97;
    --primary-color: #238636;
    --primary-hover: #2ea043;
    --secondary-bg: #21262d;
    --secondary-hover: #30363d;
    --accent-blue: #2f81f7;
    --password-bg: rgba(47, 129, 247, 0.08);
    --password-border: rgba(47, 129, 247, 0.4);
}

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

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
    background-color: var(--bg-color);
    color: var(--text-primary);
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    padding: 20px;
}

.card {
    background-color: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: 8px;
    width: 100%;
    max-width: 650px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.6);
    overflow: hidden;
}

.card-header {
    padding: 12px 20px;
    border-bottom: 1px solid var(--card-border);
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
    background-color: rgba(22, 27, 34, 0.8);
}

.icon-book {
    color: var(--text-secondary);
}

.card-body {
    padding: 30px 40px;
}

.title {
    font-size: 26px;
    font-weight: 600;
    margin-bottom: 25px;
    color: #ffffff;
}

.progress-section {
    margin-bottom: 30px;
    text-align: left;
}

.progress-bar-container {
    height: 8px;
    background-color: var(--secondary-bg);
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 12px;
    position: relative;
    border: 1px solid var(--card-border);
}

.progress-bar {
    height: 100%;
    width: 15%; /* Default for appearance */
    background: linear-gradient(90deg, #2f81f7, #58a6ff);
    border-radius: 4px;
    transition: width 0.15s ease-out;
}

.progress-bar.active {
    width: 0%;
}

.progress-bar.striped {
    background-image: linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent);
    background-size: 1rem 1rem;
    animation: progress-stripes 1s linear infinite;
}

@keyframes progress-stripes {
    0% { background-position: 1rem 0; }
    100% { background-position: 0 0; }
}

.status-text {
    font-size: 14px;
    color: var(--text-secondary);
    text-align: center;
}

.actions {
    display: flex;
    gap: 15px;
    margin-bottom: 30px;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 20px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    border: 1px solid rgba(240, 246, 252, 0.1);
    outline: none;
}

.btn-primary {
    background-color: var(--primary-color);
    color: #ffffff;
    border-color: rgba(240, 246, 252, 0.1);
}

.btn-primary:hover {
    background-color: var(--primary-hover);
    box-shadow: 0 0 20px rgba(35, 134, 54, 0.4);
}

.btn-secondary {
    background-color: var(--secondary-bg);
    color: var(--text-primary);
}

.btn-secondary:hover {
    background-color: var(--secondary-hover);
    border-color: #8b949e;
}

.password-box {
    background-color: var(--password-bg);
    border: 1px solid var(--password-border);
    border-radius: 6px;
    padding: 15px 20px;
    display: flex;
    align-items: center;
    margin-bottom: 30px;
}

.password-label {
    color: var(--text-secondary);
    margin-right: 10px;
    font-size: 15px;
}

.password-value {
    color: var(--accent-blue);
    font-size: 20px;
    font-weight: 700;
    font-family: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, "Liberation Mono", monospace;
    letter-spacing: 0.5px;
    flex-grow: 1;
}

.btn-copy {
    background: var(--secondary-bg);
    color: var(--accent-blue);
    border: 1px solid rgba(47, 129, 247, 0.3);
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-copy:hover {
    background-color: rgba(47, 129, 247, 0.15);
    border-color: var(--accent-blue);
}

.info-alert {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    background-color: rgba(47, 129, 247, 0.1);
    border: 1px solid rgba(47, 129, 247, 0.4);
    border-radius: 6px;
    padding: 16px;
    color: var(--text-primary);
    font-size: 14px;
    line-height: 1.5;
}

.info-icon {
    color: var(--accent-blue);
    flex-shrink: 0;
    margin-top: 2px;
}

/* Prominent warning for the archive notice. */
.info-alert--danger {
    background-color: rgba(248, 81, 73, 0.12);
    border-color: rgba(248, 81, 73, 0.65);
    box-shadow: 0 0 0 0 rgba(248, 81, 73, 0.35);
    margin-bottom: 20px;
    animation: alert-pulse 2.4s ease-in-out infinite;
}

.info-alert--danger .info-icon {
    color: #ff7b72;
    animation: icon-pulse 1.2s ease-in-out infinite;
}

.info-alert--danger a {
    color: #ff7b72;
    text-decoration: underline;
    text-decoration-color: rgba(255, 123, 114, 0.55);
    text-decoration-thickness: 1px;
    text-underline-offset: 3px;
    transition: color 0.2s ease, text-decoration-color 0.2s ease;
}

.info-alert--danger a:hover {
    color: #ffffff;
    text-decoration-color: currentColor;
}

.info-alert--danger a:focus-visible {
    outline: 2px solid #ff7b72;
    outline-offset: 3px;
    border-radius: 2px;
}

@keyframes alert-pulse {
    50% {
        box-shadow: 0 0 0 5px rgba(248, 81, 73, 0);
    }
}

@keyframes icon-pulse {
    50% {
        transform: scale(1.12);
    }
}

@media (prefers-reduced-motion: reduce) {
    .info-alert--danger,
    .info-alert--danger .info-icon {
        animation: none;
    }
}

.powershell-box {
    margin-bottom: 30px;
    border: 1px solid var(--card-border);
    border-radius: 8px;
    background-color: rgba(22, 27, 34, 0.3);
    padding: 16px 20px;
}

.powershell-header {
    margin-bottom: 12px;
}

.powershell-label {
    display: block;
    color: var(--accent-blue);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.5px;
    margin-bottom: 6px;
}

.powershell-title {
    color: var(--text-primary);
    font-size: 15px;
    font-weight: 600;
}

.powershell-code-container {
    background-color: #010409;
    border: 1px solid var(--card-border);
    border-radius: 6px;
    display: flex;
    align-items: center;
    padding: 10px 15px;
}

.powershell-code {
    font-family: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, "Liberation Mono", monospace;
    color: #e6edf3;
    font-size: 14px;
    flex-grow: 1;
}

.btn-copy-icon {
    background: var(--secondary-bg);
    color: var(--text-secondary);
    border: 1px solid rgba(240, 246, 252, 0.1);
    padding: 6px;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.btn-copy-icon:hover {
    background-color: var(--secondary-hover);
    color: var(--text-primary);
    border-color: #8b949e;
}

/* Modal Styles */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-color: rgba(1, 4, 9, 0.8);
    backdrop-filter: blur(4px);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s ease;
}

.modal-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

.modal-content {
    background-color: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: 8px;
    width: 90%;
    max-width: 550px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.8);
    transform: translateY(20px);
    transition: transform 0.2s ease;
}

.modal-overlay.active .modal-content {
    transform: translateY(0);
}

.modal-header {
    padding: 16px 24px;
    border-bottom: 1px solid var(--card-border);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h2 {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-primary);
}

.modal-close {
    background: transparent;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
    transition: all 0.2s;
}

.modal-close:hover {
    color: var(--text-primary);
    background-color: rgba(240, 246, 252, 0.1);
}

.modal-body {
    padding: 24px;
    max-height: 70vh;
    overflow-y: auto;
}

.instruction-step {
    margin-bottom: 24px;
}

.instruction-step:last-child {
    margin-bottom: 0;
}

.step-title {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 8px;
}

.step-desc {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.5;
}

/* Animations */
.pulse {
    animation: pulse-animation 2.5s infinite;
}

@keyframes pulse-animation {
    0% { box-shadow: 0 0 0 0 rgba(35, 134, 54, 0.6); }
    70% { box-shadow: 0 0 0 10px rgba(35, 134, 54, 0); }
    100% { box-shadow: 0 0 0 0 rgba(35, 134, 54, 0); }
}
