:root {
    /* Default theme (dark) */
    --bg: #121212;
    --surface: #1e1e1e;
    --text: #f5f5f5;
    --text-secondary: #b0b0b0;
    --border: #333333;
    --accent: #4285f4;
    --accent-hover: #5c9aff;
    --danger: #ff6b6b;
    --success: #4cd964;
    --input-bg: #2a2a2a;
    
    /* Animation speeds */
    --transition-speed: 0.3s;
}

/* Light theme variables */
[data-theme="light"] {
    --bg: #f5f5f5;
    --surface: #ffffff;
    --text: #333333;
    --text-secondary: #666666;
    --border: #e0e0e0;
    --accent: #4285f4;
    --accent-hover: #3367d6;
    --danger: #ea4335;
    --success: #34a853;
    --input-bg: #f8f8f8;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Poppins', sans-serif;
    background: var(--bg);
    color: var(--text);
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: background-color var(--transition-speed) ease;
}

.container {
    width: 90%;
    max-width: 500px;
    margin: 2rem 0;
}

header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

h1 {
    font-size: 2rem;
    font-weight: 700;
    color: var(--accent);
}

#themeToggle {
    background: transparent;
    border: none;
    color: var(--text);
    font-size: 1.5rem;
    cursor: pointer;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition-speed) ease;
}

#themeToggle:hover {
    background-color: rgba(128, 128, 128, 0.1);
    transform: rotate(15deg);
}

.card {
    background: var(--surface);
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
    transition: all var(--transition-speed) ease;
}

.tabs {
    display: flex;
    border-bottom: 1px solid var(--border);
}

.tab-btn {
    flex: 1;
    padding: 1rem;
    border: none;
    background: transparent;
    color: var(--text-secondary);
    font-family: 'Poppins', sans-serif;
    font-weight: 500;
    font-size: 1rem;
    cursor: pointer;
    transition: all var(--transition-speed) ease;
}

.tab-btn.active {
    color: var(--accent);
    box-shadow: inset 0 -3px 0 var(--accent);
}

.tab-content {
    padding: 1.5rem;
}

.input-container {
    position: relative;
    margin-bottom: 1.5rem;
}

#linkInput {
    width: 100%;
    padding: 1rem 3rem 1rem 1rem;
    border-radius: 8px;
    border: 1px solid var(--border);
    background: var(--input-bg);
    color: var(--text);
    font-family: 'Poppins', sans-serif;
    font-size: 1rem;
    transition: all var(--transition-speed) ease;
}

#linkInput:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 2px rgba(66, 133, 244, 0.2);
}

#pasteButton {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    background: transparent;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    font-size: 1.2rem;
    transition: color var(--transition-speed) ease;
}

#pasteButton:hover {
    color: var(--accent);
}

.action-button {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    font-family: 'Poppins', sans-serif;
    font-weight: 500;
    font-size: 1rem;
    cursor: pointer;
    transition: all var(--transition-speed) ease;
    border: none;
    width: 100%;
}

.action-button.primary {
    background: var(--accent);
    color: white;
}

.action-button.primary:hover {
    background: var(--accent-hover);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(66, 133, 244, 0.3);
}

.action-button.secondary {
    background: rgba(128, 128, 128, 0.1);
    color: var(--text);
}

.action-button.secondary:hover {
    background: rgba(128, 128, 128, 0.2);
    transform: translateY(-2px);
}

.result-container {
    margin-top: 1.5rem;
    padding: 1.5rem;
    border-radius: 8px;
    background: rgba(128, 128, 128, 0.05);
    border: 1px solid var(--border);
    animation: fadeIn 0.5s ease forwards;
}

.qr-code-display {
    background: white;
    padding: 1rem;
    border-radius: 8px;
    margin: 0 auto 1.5rem;
    width: fit-content;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.action-buttons {
    display: flex;
    gap: 1rem;
}

.drop-area {
    border: 2px dashed var(--border);
    border-radius: 8px;
    padding: 2.5rem;
    text-align: center;
    transition: all var(--transition-speed) ease;
    margin-bottom: 1rem;
}

.drop-area.active {
    border-color: var(--accent);
    background: rgba(66, 133, 244, 0.05);
}

.scanned-result h3 {
    margin-bottom: 1rem;
    color: var(--text);
    font-weight: 500;
}

#scannedLink {
    width: 100%;
    padding: 0.75rem 1rem;
    border-radius: 8px;
    border: 1px solid var(--border);
    background: var(--input-bg);
    color: var(--text);
    font-family: 'Poppins', sans-serif;
    margin-bottom: 1.5rem;
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Responsive styles */
@media (max-width: 768px) {
    .container {
        width: 95%;
    }
    
    h1 {
        font-size: 1.7rem;
    }
}

@media (max-width: 480px) {
    h1 {
        font-size: 1.5rem;
    }
    
    .tab-btn {
        padding: 0.75rem;
        font-size: 0.9rem;
    }
    
    .tab-content {
        padding: 1rem;
    }
    
    .action-button {
        font-size: 0.9rem;
        padding: 0.8rem 0;
    }
    
    .drop-area {
        padding: 1.5rem;
    }
    
    .action-buttons {
        gap: 0.8rem;
    }
}