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

:root {
    --primary-color: #3182ce;
    --success-color: #38a169;
    --secondary-color: #4a5568;
    --background-color: #f7fafc;
    --card-background: #ffffff;
    --text-primary: #2d3748;
    --text-secondary: #4a5568;
    --border-color: #e2e8f0;
    --hover-color: #ebf8ff;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    color: var(--text-primary);
    background-color: var(--background-color);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.container {
    max-width: 800px;
    margin: 2rem auto;
    padding: 0 1rem;
}

/* Header styles */
.app-header {
    text-align: center;
    margin-bottom: 2rem;
}

.app-header h1 {
    font-size: 2.5rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.subtitle {
    color: var(--text-secondary);
    font-size: 1.1rem;
}

/* Card styles */
.main-card {
    background: var(--card-background);
    border-radius: 12px;
    padding: 2rem;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05), 0 10px 15px rgba(0, 0, 0, 0.1);
}

/* Steps */
.steps {
    display: flex;
    flex-direction: column;
    gap: 2rem;
    margin-bottom: 2rem;
}

.step {
    display: flex;
    gap: 1rem;
    opacity: 0.7;
    transition: opacity 0.3s ease;
}

.step.active {
    opacity: 1;
}

.step-number {
    width: 32px;
    height: 32px;
    background: var(--primary-color);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    flex-shrink: 0;
}

.step-content {
    flex-grow: 1;
}

.step-content h3 {
    margin-bottom: 1rem;
    color: var(--text-primary);
}

/* Drop zone styles */
.drop-zone {
    border: 2px dashed var(--border-color);
    border-radius: 12px;
    padding: 2rem;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
}

.drop-zone:hover,
.drop-zone.drag-over {
    border-color: var(--primary-color);
    background-color: var(--hover-color);
}

.drop-zone-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
}

.upload-icon {
    width: 48px;
    height: 48px;
    fill: var(--primary-color);
}

.file-input {
    display: none;
}

/* Button styles */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
    font-weight: 500;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    border: none;
    width: auto;
    min-width: 120px;
}

.btn svg {
    width: 20px;
    height: 20px;
    fill: currentColor;
}

.btn-primary {
    background-color: var(--primary-color);
    color: white;
}

.btn-primary:hover {
    background-color: #2c5282;
}

.btn-secondary {
    background-color: var(--secondary-color);
    color: white;
}

.btn-secondary:hover {
    background-color: #2d3748;
}

.btn-success {
    background-color: var(--success-color);
    color: white;
}

.btn-success:hover {
    background-color: #2f855a;
}

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

/* Status and URL display */
.status-container {
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 1px solid var(--border-color);
}

.status {
    text-align: center;
    padding: 1rem;
    border-radius: 8px;
    background-color: var(--background-color);
    color: var(--text-secondary);
    font-weight: 500;
}

.session-url {
    margin-top: 1rem;
    padding: 1rem;
    background-color: var(--background-color);
    border-radius: 8px;
    border: 1px solid var(--border-color);
    word-break: break-all;
    font-family: monospace;
    font-size: 0.9rem;
}

/* Payment toggle */
.payment-toggle {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
}

.switch-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
}

.toggle-label {
    font-weight: 500;
    color: var(--text-secondary);
}

/* Payment details */
.payment-details {
    background-color: var(--background-color);
    border-radius: 8px;
    padding: 1rem;
    margin-top: 1rem;
}

.input-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.input-group label {
    font-weight: 500;
    color: var(--text-secondary);
}

.input-group input {
    padding: 0.75rem;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    font-size: 1rem;
    width: 100%;
}

/* File info display */
.file-details {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    padding: 1.5rem;
    background-color: var(--background-color);
    border-radius: 8px;
}

.file-icon {
    width: 40px;
    height: 40px;
    fill: var(--primary-color);
}

.file-text h3 {
    margin-bottom: 0.5rem;
}

.file-name {
    font-weight: 500;
    margin-bottom: 0.25rem;
}

.file-size {
    color: var(--text-secondary);
}

/* Invoice display */
.payment-card {
    background-color: var(--background-color);
    border-radius: 8px;
    padding: 1.5rem;
    text-align: center;
}

.qr-container {
    margin: 1.5rem auto;
    padding: 1rem;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    display: inline-block;
}

.invoice-details {
    margin: 1rem 0;
}

.invoice-text {
    font-family: monospace;
    font-size: 0.875rem;
    padding: 1rem;
    background-color: white;
    border-radius: 6px;
    margin-bottom: 1rem;
    word-break: break-all;
    border: 1px solid var(--border-color);
}

.payment-instructions {
    color: var(--text-secondary);
    margin-top: 1rem;
}

/* Debug info */
.debug-info {
    margin-top: 1rem;
    padding: 1rem;
    background-color: var(--background-color);
    border-radius: 8px;
    font-family: monospace;
    font-size: 0.875rem;
}

.debug-grid {
    display: grid;
    gap: 0.5rem;
    margin-top: 0.5rem;
}

.debug-item {
    display: flex;
    justify-content: space-between;
    padding: 0.5rem;
    background-color: white;
    border-radius: 4px;
}

.debug-label {
    color: var(--text-secondary);
    font-weight: 500;
}

/* Responsive design */
@media (max-width: 640px) {
    .container {
        margin: 1rem auto;
    }

    .main-card {
        padding: 1rem;
    }

    .steps {
        gap: 1.5rem;
    }

    .file-details {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .btn {
        width: 100%;
    }
}