:root {
    --bg-primary: #ffffff;
    --text-primary: #333333;
    --text-secondary: #555555;
    --text-muted: #888888;
    
    --primary: #ff6550; /* Orange-red coral button color */
    --primary-hover: #e04f3b;
    --primary-glow: rgba(255, 101, 80, 0.2);
    
    --border-color: #dcdcdc;
    --border-focus: #4a90e2;
    
    --success: #10b981;
    --success-bg: rgba(16, 185, 129, 0.1);
    --error: #ef4444;
    --error-bg: rgba(239, 68, 68, 0.1);
    
    --font-main: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    --font-display: 'Outfit', sans-serif;
    
    --card-shadow: 0 10px 30px rgba(0, 0, 0, 0.04);
}

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

body {
    background-color: #fcfdfe;
    color: var(--text-primary);
    font-family: var(--font-main);
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

/* App Container */
.app-container {
    width: 100%;
    max-width: 520px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 24px;
}

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

.app-title {
    font-family: var(--font-display);
    font-size: 1.8rem;
    font-weight: 500;
    color: #4a5568;
    margin-bottom: 8px;
    letter-spacing: -0.3px;
}

.app-subtitle {
    color: #718096;
    font-size: 1rem;
    font-weight: 400;
}

/* Views */
.view-state {
    display: none;
    flex-direction: column;
    width: 100%;
    animation: fadeIn 0.3s ease-out forwards;
}

.view-state.active {
    display: flex;
}

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

/* Main Form Layout */
.main-form {
    display: flex;
    flex-direction: column;
    gap: 28px;
    width: 100%;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.form-label {
    font-size: 1.05rem;
    font-weight: 600;
    color: #4a5568;
}

.required {
    color: var(--primary);
    margin-left: 2px;
}

/* Custom File Input design matching Screenshot */
.custom-file-input-wrapper {
    position: relative;
    width: 100%;
    height: 52px;
    background: #ffffff;
    border: 1px solid #d2d6dc;
    border-radius: 8px;
    display: flex;
    align-items: center;
    padding: 0 16px;
    cursor: pointer;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.custom-file-input-wrapper:hover, .custom-file-input-wrapper.dragover {
    border-color: #cbd5e0;
}

.real-file-input {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: pointer;
    z-index: 10;
}

.file-dummy-btn {
    background-color: #efefef;
    border: 1px solid #767676;
    border-radius: 2px;
    color: #000000;
    padding: 4px 10px;
    font-size: 0.85rem;
    font-family: inherit;
    cursor: pointer;
    margin-right: 12px;
    pointer-events: none;
    z-index: 1;
}

.file-dummy-text {
    font-size: 0.95rem;
    color: #4a5568;
    pointer-events: none;
    z-index: 1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: calc(100% - 130px);
}

/* Email Input Field */
.email-input-field {
    width: 100%;
    height: 52px;
    padding: 0 16px;
    border: 1px solid #d2d6dc;
    border-radius: 8px;
    background: #ffffff;
    color: var(--text-primary);
    font-family: inherit;
    font-size: 1rem;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.email-input-field:focus {
    outline: none;
    border-color: #b3d4fc;
    box-shadow: 0 0 0 3px rgba(66, 153, 225, 0.15);
}

.email-input-field::placeholder {
    color: #a0aec0;
}

/* Red-Orange Submit Button */
.submit-button {
    width: 100%;
    height: 54px;
    background: var(--primary);
    color: #ffffff;
    border: none;
    border-radius: 8px;
    font-family: var(--font-main);
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.2s ease, transform 0.1s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.submit-button:hover {
    background: var(--primary-hover);
}

.submit-button:active {
    transform: scale(0.995);
}

/* Status Card */
.card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    box-shadow: var(--card-shadow);
    padding: 32px;
    text-align: center;
}

.status-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
}

/* Processing Spinner */
.spinner-wrapper {
    position: relative;
    width: 72px;
    height: 72px;
    margin-bottom: 20px;
}

.spinner {
    position: absolute;
    width: 100%;
    height: 100%;
    border: 3px solid rgba(255, 101, 80, 0.1);
    border-top: 3px solid var(--primary);
    border-radius: 50%;
    animation: rotateSpinner 1s linear infinite;
}

.spinner-icon {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 24px;
    height: 24px;
    color: var(--primary);
}

@keyframes rotateSpinner {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.status-title {
    font-family: var(--font-display);
    font-size: 1.35rem;
    font-weight: 600;
    color: #2d3748;
    margin-bottom: 6px;
}

.status-subtitle {
    color: #718096;
    font-size: 0.95rem;
    margin-bottom: 20px;
    max-width: 90%;
    word-break: break-all;
}

.status-info {
    color: var(--text-muted);
    font-size: 0.85rem;
    max-width: 85%;
    margin-top: 10px;
}

/* Progress Bar */
.progress-bar-container {
    width: 80%;
    height: 5px;
    background: #edf2f7;
    border-radius: 100px;
    overflow: hidden;
    margin-bottom: 12px;
}

.progress-bar-fill {
    height: 100%;
    width: 0%;
    background: var(--primary);
    border-radius: 100px;
    transition: width 0.3s ease;
}

/* Success & Error Icons */
.success-icon-wrapper, .error-icon-wrapper {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 18px;
}

.success-icon-wrapper {
    background: var(--success-bg);
    color: var(--success);
}

.error-icon-wrapper {
    background: var(--error-bg);
    color: var(--error);
}

.success-icon, .error-icon {
    width: 32px;
    height: 32px;
}

/* File details */
.file-details-card {
    background: #f7fafc;
    border: 1px solid #edf2f7;
    border-radius: 8px;
    padding: 14px 18px;
    width: 100%;
    max-width: 380px;
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 24px;
    text-align: left;
}

.excel-icon {
    width: 24px;
    height: 24px;
    color: var(--primary);
}

.file-info {
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.file-info-name {
    font-weight: 550;
    font-size: 0.9rem;
    color: #2d3748;
}

.file-info-size {
    font-size: 0.8rem;
    color: var(--text-muted);
}

/* Auth / Login */
.login-container {
    max-width: 420px;
}

.login-error {
    color: var(--error);
    background: var(--error-bg);
    border: 1px solid rgba(239, 68, 68, 0.25);
    border-radius: 8px;
    padding: 12px 14px;
    font-size: 0.9rem;
    text-align: center;
}

.top-bar {
    display: flex;
    justify-content: flex-end;
    margin-bottom: 4px;
}

.logout-button {
    background: transparent;
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    border-radius: 8px;
    padding: 8px 14px;
    font-family: var(--font-main);
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}

.logout-button:hover {
    background: #f7fafc;
    border-color: #cbd5e0;
    color: var(--text-primary);
}

.submit-button:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

