:root {
    --primary-blue: #4361EE;
    --coral: #E86850;
    --bg-cream: #FAFAF8;
    --white: #FFFFFF;
    --text-dark: #1a1a1a;
    --text-gray: #6b7280;
    --border-light: #e5e7eb;
}

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

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-cream);
    min-height: 100vh;
    overflow-x: hidden;
}

.app-container {
    min-height: 100vh;
    position: relative;
    display: flex;
    flex-direction: column;
}

/* Halftone Hands */
.halftone-hand {
    position: fixed;
    top: 50%;
    transform: translateY(-50%);
    pointer-events: none;
    opacity: 0.9;
    animation: breathe 8s ease-in-out infinite;
}

.halftone-hand-left {
    left: -50px;
}

.halftone-hand-right {
    right: -50px;
}

@keyframes breathe {
    0%, 100% {
        transform: translateY(-50%) scale(1);
        opacity: 0.9;
    }
    50% {
        transform: translateY(-50%) scale(1.02);
        opacity: 0.95;
    }
}

/* Header */
.header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 24px;
    position: relative;
    z-index: 10;
}

.upgrade-btn {
    display: flex;
    align-items: center;
    background-color: var(--coral);
    color: white;
    padding: 10px 16px;
    border-radius: 8px;
    border: none;
    font-weight: 500;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.upgrade-btn:hover {
    background-color: #d55a44;
    transform: scale(1.02);
}

.settings-btn {
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
    color: var(--text-gray);
    transition: all 0.3s ease;
}

.settings-btn:hover .gear-icon {
    transform: rotate(90deg);
    color: var(--text-dark);
}

.gear-icon {
    transition: transform 0.3s ease;
}

/* Main Content */
.main-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 20px;
    position: relative;
    z-index: 5;
}

/* Logo */
.logo {
    font-family: 'Fredoka', sans-serif;
    font-size: clamp(48px, 10vw, 80px);
    font-weight: 600;
    color: var(--primary-blue);
    margin-bottom: 40px;
    letter-spacing: -2px;
    font-style: italic;
    text-shadow: 2px 2px 0 rgba(67, 97, 238, 0.1);
}

/* Prompt Card */
.prompt-card {
    background: var(--white);
    border-radius: 12px;
    border: 1px solid var(--border-light);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
    padding: 20px;
    width: 100%;
    max-width: 600px;
    margin-bottom: 20px;
}

.prompt-input {
    width: 100%;
    border: none;
    outline: none;
    font-family: 'Inter', sans-serif;
    font-size: 15px;
    line-height: 1.6;
    resize: none;
    color: var(--text-dark);
    background: transparent;
    margin-bottom: 16px;
}

.prompt-input::placeholder {
    color: var(--text-gray);
}

/* Action Row */
.action-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.action-left {
    display: flex;
    align-items: center;
    gap: 12px;
}

.refine-btn {
    display: flex;
    align-items: center;
    background: none;
    border: none;
    color: var(--text-gray);
    font-size: 14px;
    cursor: pointer;
    transition: color 0.2s ease;
}

.refine-btn:hover {
    color: var(--primary-blue);
}

.auto-mode-btn {
    padding: 6px 14px;
    border-radius: 6px;
    border: 1px solid var(--border-light);
    background: var(--white);
    font-size: 13px;
    color: var(--text-dark);
    cursor: pointer;
    transition: all 0.2s ease;
}

.auto-mode-btn:hover {
    border-color: var(--primary-blue);
}

.auto-mode-btn.active {
    background: var(--primary-blue);
    color: white;
    border-color: var(--primary-blue);
}

.submit-btn {
    width: 44px;
    height: 44px;
    border-radius: 8px;
    background: var(--primary-blue);
    border: none;
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.submit-btn:hover {
    background: #3651d4;
    transform: scale(1.05);
}

/* Bottom Buttons */
.bottom-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    justify-content: center;
    align-items: center;
}

.toggle-group {
    display: flex;
    border-radius: 8px;
    overflow: hidden;
    border: 1px solid var(--border-light);
}

.toggle-btn {
    padding: 10px 18px;
    border: none;
    background: var(--white);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    color: var(--text-dark);
}

.toggle-btn:first-child {
    border-right: 1px solid var(--border-light);
}

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

.toggle-btn-coral.active {
    background: var(--coral);
}

.repo-btn {
    display: flex;
    align-items: center;
    padding: 10px 18px;
    border-radius: 8px;
    border: 1px solid var(--primary-blue);
    background: var(--white);
    color: var(--primary-blue);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

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

.config-btn {
    display: flex;
    align-items: center;
    padding: 10px 18px;
    border-radius: 8px;
    border: 1px solid var(--coral);
    background: var(--white);
    color: var(--coral);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.config-btn:hover {
    background: var(--coral);
    color: white;
}

.config-btn svg {
    width: 16px;
    height: 16px;
}

/* Footer */
.footer {
    text-align: center;
    padding: 20px;
    position: relative;
    z-index: 10;
}

.footer a {
    color: var(--text-gray);
    text-decoration: none;
    font-size: 13px;
    transition: color 0.2s ease;
}

.footer a:hover {
    color: var(--primary-blue);
}

/* Responsive */
@media (max-width: 768px) {
    .halftone-hand {
        display: none;
    }
    
    .prompt-card {
        max-width: 100%;
    }
    
    .bottom-buttons {
        flex-direction: column;
        width: 100%;
        max-width: 400px;
    }
    
    .toggle-group,
    .repo-btn,
    .config-btn {
        width: 100%;
        justify-content: center;
    }
    
    .toggle-btn {
        flex: 1;
    }
}

@media (max-width: 480px) {
    .header {
        padding: 12px 16px;
    }
    
    .logo {
        font-size: 36px;
        margin-bottom: 24px;
    }
    
    .main-content {
        padding: 16px;
    }
}