:root {
    --bg-color: #0f172a;
    --card-bg: #1e293b;
    --text-primary: #f8fafc;
    --text-secondary: #94a3b8;
    --accent: #3b82f6;
    --accent-hover: #2563eb;
    --border: #334155;
    --danger: #ef4444;
    --success: #22c55e;
}

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

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

.app-container {
    width: 100%;
    max-width: 500px;
    background: var(--card-bg);
    border-radius: 24px;
    padding: 32px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    border: 1px solid var(--border);
}

header {
    text-align: center;
    margin-bottom: 32px;
}

header h1 {
    font-size: 2rem;
    font-weight: 800;
    letter-spacing: -0.05em;
    margin-bottom: 8px;
}

.dot {
    color: var(--accent);
}

header p {
    color: var(--text-secondary);
    font-size: 0.95rem;
}

/* Tabs */
.tabs {
    display: flex;
    background: var(--bg-color);
    padding: 4px;
    border-radius: 12px;
    margin-bottom: 24px;
}

.tab-btn {
    flex: 1;
    background: none;
    border: none;
    padding: 10px;
    color: var(--text-secondary);
    font-weight: 600;
    cursor: pointer;
    border-radius: 8px;
    transition: all 0.2s ease;
}

.tab-btn.active {
    background: var(--card-bg);
    color: var(--text-primary);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

/* Drop Zone */
.drop-zone {
    border: 2px dashed var(--border);
    border-radius: 16px;
    padding: 40px 20px;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s ease;
    margin-bottom: 24px;
}

.drop-zone:hover, .drop-zone.drag-over {
    border-color: var(--accent);
    background: rgba(59, 130, 246, 0.05);
}

.drop-content svg {
    color: var(--text-secondary);
    margin-bottom: 12px;
}

.drop-content p {
    font-weight: 600;
    margin-bottom: 4px;
}

.sub-text {
    font-size: 0.85rem;
    color: var(--text-secondary);
}

/* Image Preview */
#image-preview-container {
    position: relative;
    margin-bottom: 24px;
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid var(--border);
}

#image-preview-container.hidden {
    display: none;
}

#preview-img {
    width: 100%;
    display: block;
}

#remove-img {
    position: absolute;
    top: 8px;
    right: 8px;
    background: rgba(0, 0, 0, 0.6);
    color: white;
    border: none;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    transition: background 0.2s;
}

#remove-img:hover {
    background: var(--danger);
}

/* Panels */
.panel {
    display: none;
    animation: fadeIn 0.3s ease;
}

.panel.active {
    display: block;
}

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

/* Inputs */
.input-group {
    margin-bottom: 20px;
}

label {
    display: block;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 8px;
    color: var(--text-secondary);
}

textarea {
    width: 100%;
    height: 100px;
    background: var(--bg-color);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 12px;
    color: var(--text-primary);
    font-family: inherit;
    resize: none;
    outline: none;
    transition: border-color 0.2s;
}

textarea:focus {
    border-color: var(--accent);
}

.output-box {
    width: 100%;
    min-height: 100px;
    background: var(--bg-color);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 12px;
    color: var(--text-primary);
    word-break: break-all;
}

.output-box.placeholder {
    color: var(--text-secondary);
    font-style: italic;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Buttons */
.primary-btn {
    width: 100%;
    padding: 14px;
    background: var(--accent);
    color: white;
    border: none;
    border-radius: 12px;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: background 0.2s;
}

.primary-btn:hover:not(:disabled) {
    background: var(--accent-hover);
}

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