
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@400;600;700&display=swap');

:root {
    --primary-color: #3B82F6;
    --secondary-color: #10B981;
    --background-color: #F9FAFB;
    --text-color: #1F2937;
    --card-background: #FFFFFF;
    --light-gray: #E5E7EB;
    --shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --border-radius: 12px;
}

[data-theme="dark"] {
    --primary-color: #60A5FA;
    --secondary-color: #34D399;
    --background-color: #111827;
    --text-color: #F9FAFB;
    --card-background: #1F2937;
    --light-gray: #374151;
}

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

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

#app {
    width: 100%;
    max-width: 500px;
    background-color: var(--card-background);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    overflow: hidden;
    position: relative;
    transition: background-color 0.3s;
}

.header-controls {
    position: absolute;
    top: 20px;
    right: 20px;
    z-index: 10;
    display: flex;
    gap: 10px;
    align-items: center; /* Align items vertically */
}

.theme-toggle-container {
    position: relative;
    top: 0;
    right: 0;
}

#theme-toggle {
    background: transparent;
    border: 2px solid var(--light-gray);
    border-radius: 50%;
    cursor: pointer;
    padding: 6px;
    display: flex;
    justify-content: center;
    align-items: center;
    box-shadow: none;
}

#theme-toggle svg {
    stroke: var(--text-color);
}

#theme-toggle .sun {
    display: none;
}

#theme-toggle .moon {
    display: block;
}

[data-theme="dark"] #theme-toggle .sun {
    display: block;
}

[data-theme="dark"] #theme-toggle .moon {
    display: none;
}


.screen {
    padding: 40px;
    padding-top: 80px; /* Add padding to account for header controls */
    text-align: center;
    animation: fadeIn 0.5s ease-in-out;
}

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

h1 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 20px;
}

p {
    font-size: 1.1rem;
    margin-bottom: 30px;
}

button {
    background-color: var(--primary-color);
    color: white;
    font-size: 1rem;
    font-weight: 600;
    padding: 15px 30px;
    border: none;
    border-radius: var(--border-radius);
    cursor: pointer;
    transition: background-color 0.3s, transform 0.2s;
    box-shadow: 0 4px 6px rgba(59, 130, 246, 0.3);
}

button:hover {
    background-color: #2563EB;
    transform: translateY(-2px);
}

button:disabled {
    background-color: var(--light-gray);
    cursor: not-allowed;
    box-shadow: none;
    transform: none;
}

/* TM Screen */
#lang-switcher-container.dropdown {
    position: relative;
    display: inline-block;
}

.dropdown-toggle {
    background: transparent;
    border: 2px solid var(--light-gray);
    border-radius: 8px;
    color: var(--text-color);
    padding: 5px 10px;
    cursor: pointer;
    box-shadow: none;
    width: 100px; /* Fixed width for consistency */
}

.dropdown-content {
    display: none;
    position: absolute;
    background-color: var(--card-background);
    min-width: 100px;
    box-shadow: var(--shadow);
    border-radius: var(--border-radius);
    z-index: 1;
    right: 0; /* Align dropdown to the right */
    margin-top: 5px;
    overflow: hidden;
}

.dropdown-content button {
    color: var(--text-color);
    padding: 12px 16px;
    text-decoration: none;
    display: block;
    border: none;
    background: none;
    text-align: left;
    width: 100%;
    border-radius: 0; /* Remove border-radius for individual buttons in dropdown */
}

.dropdown-content button:hover {
    background-color: var(--light-gray);
}

.dropdown.show .dropdown-content {
    display: block;
}

#image-preview-container {
    margin: 20px auto;
    width: 224px;
    height: 224px;
    border: 2px dashed var(--light-gray);
    border-radius: var(--border-radius);
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
}

#image-preview {
    max-width: 100%;
    max-height: 100%;
}

#label-container {
    margin-top: 20px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    font-size: 1.2rem;
    font-weight: 600;
}
