:root {
    --primary: #007AFF;
    --primary-hover: #005bb5;
    --danger: #FF3B30;
    --danger-hover: #d70015;
    --success: #34C759;
    --success-hover: #2eb050;
    --text-main: #1c1c1e;
    --text-muted: #8e8e93;
    --bg-body: #f2f2f7;
    --bg-container: rgba(255, 255, 255, 0.85);
    --border-color: rgba(255, 255, 255, 0.4);
    --shadow: 0 10px 40px rgba(0, 0, 0, 0.08);
}
body {
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    background-color: var(--bg-body);
    margin: 0;
    color: var(--text-main);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}
.app-wrapper {
    flex: 1;
    padding: 40px 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    box-sizing: border-box;
}
/* Bubble Background */
.bubble-bg {
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    z-index: -1;
    overflow: hidden;
    pointer-events: none;
}
.bubble {
    position: absolute;
    border-radius: 50%;
    background: rgba(0, 122, 255, 0.08);
    animation: float 15s infinite ease-in-out alternate;
    filter: blur(40px);
}
.bubble-1 { width: 400px; height: 400px; top: -100px; left: -100px; }
.bubble-2 { width: 500px; height: 500px; bottom: -150px; right: -100px; animation-delay: -2s; background: rgba(52, 199, 89, 0.08); }
.bubble-3 { width: 300px; height: 300px; bottom: 20%; left: 20%; animation-delay: -5s; background: rgba(255, 59, 48, 0.05); }

@keyframes float {
    0% { transform: translate(0, 0) scale(1); }
    100% { transform: translate(50px, -50px) scale(1.1); }
}
.container {
    background: var(--bg-container);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    padding: 30px;
    border-radius: 20px;
    box-shadow: var(--shadow);
    border: 1px solid var(--border-color);
    width: 100%;
    max-width: 900px;
    box-sizing: border-box;
    z-index: 1;
}
h1 {
    margin-top: 0;
    color: var(--text-main);
    text-align: center;
    font-weight: 700;
}
p.subtitle {
    text-align: center;
    color: var(--text-muted);
    margin-bottom: 20px;
    font-size: 15px;
}
textarea {
    width: 100%;
    height: 250px;
    padding: 15px;
    border: 1px solid #d1d1d6;
    border-radius: 12px;
    resize: vertical;
    font-family: monospace;
    font-size: 14px;
    box-sizing: border-box;
    margin-bottom: 20px;
    transition: border-color 0.3s;
    background: rgba(255,255,255,0.8);
    color: var(--text-main);
}
textarea:focus {
    border-color: var(--primary);
    outline: none;
    box-shadow: 0 0 0 3px rgba(0, 122, 255, 0.15);
}
.options {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-bottom: 20px;
    font-size: 14px;
    color: var(--text-main);
    font-weight: 500;
}
.options input[type="number"] {
    width: 50px;
    padding: 8px;
    border: 1px solid #d1d1d6;
    border-radius: 8px;
    text-align: center;
    transition: border-color 0.3s;
    font-family: inherit;
    background: rgba(255,255,255,0.8);
    color: var(--text-main);
}
.options input[type="number"]:focus {
    border-color: var(--primary);
    outline: none;
    box-shadow: 0 0 0 3px rgba(0, 122, 255, 0.15);
}
.controls {
    display: flex;
    gap: 15px;
    justify-content: center;
    flex-wrap: wrap;
}
button {
    padding: 12px 24px;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    font-family: inherit;
    transition: background 0.3s, transform 0.1s;
}
button:active {
    transform: scale(0.96);
}
button:disabled {
    background-color: #d1d1d6;
    color: #8e8e93;
    cursor: not-allowed;
    transform: none;
    box-shadow: none !important;
}
.btn-primary {
    background-color: var(--primary);
    color: white;
    box-shadow: 0 4px 12px rgba(0, 122, 255, 0.3);
}
.btn-primary:hover {
    background-color: var(--primary-hover);
}
.btn-success {
    background-color: var(--success);
    color: white;
    box-shadow: 0 4px 12px rgba(52, 199, 89, 0.3);
}
.btn-success:hover {
    background-color: var(--success-hover);
}
.btn-danger {
    background-color: var(--danger);
    color: white;
    box-shadow: 0 4px 12px rgba(255, 59, 48, 0.3);
}
.btn-danger:hover:not(:disabled) {
    background-color: var(--danger-hover);
}
.btn-secondary {
    background-color: #e5e5ea;
    color: var(--text-main);
}
.btn-secondary:hover {
    background-color: #d1d1d6;
}
.warning {
    font-size: 14px;
    color: var(--danger);
    margin-top: 20px;
    text-align: center;
    background: rgba(255, 59, 48, 0.1);
    padding: 12px;
    border-radius: 8px;
    font-weight: 500;
}
.overlay {
    position: fixed;
    top: 0; 
    left: 0; 
    width: 100%; 
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}
.modal {
    background: var(--bg-container);
    padding: 40px;
    border-radius: 20px;
    text-align: center;
    max-width: 450px;
    width: 90%;
    box-shadow: var(--shadow);
    border: 1px solid var(--border-color);
}
.modal h2 {
    margin-top: 0;
    color: var(--text-main);
}
.progress-container {
    width: 100%;
    margin-top: 20px;
}
.progress-text {
    font-size: 14px;
    color: var(--text-main);
    margin-bottom: 5px;
    text-align: center;
    font-weight: bold;
}
.progress-bar-bg {
    width: 100%;
    background-color: #d1d1d6;
    border-radius: 6px;
    height: 12px;
    overflow: hidden;
}
.progress-bar-fill {
    width: 0%;
    height: 100%;
    background-color: var(--primary);
    transition: width 0.3s ease;
}
.hidden {
    display: none !important;
}

.info-container {
    background: var(--bg-container);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    padding: 30px;
    border-radius: 20px;
    box-shadow: var(--shadow);
    border: 1px solid var(--border-color);
    width: 98%;
    max-width: 1200px;
    box-sizing: border-box;
    z-index: 1;
    margin-top: 30px;
}
.info-container h2 {
    color: var(--text-main);
    margin-top: 0;
    margin-bottom: 15px;
    font-size: 22px;
}
.info-container p, .info-container li {
    color: var(--text-main);
    line-height: 1.6;
    margin-bottom: 10px;
    font-size: 15px;
}
.faq-item {
    border-bottom: 1px solid rgba(0,0,0,0.1);
    margin-bottom: 10px;
}
.faq-item:last-child {
    border-bottom: none;
}
.faq-question {
    width: 100%;
    max-width: none;
    margin: 0;
    background: none;
    border: none;
    text-align: left;
    padding: 15px 0;
    font-size: 16px;
    font-weight: 600;
    color: var(--text-main);
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-family: inherit;
    box-shadow: none !important;
    border-radius: 0;
}
.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease-out;
}
.faq-answer p {
    padding-bottom: 15px;
    color: var(--text-muted);
    margin: 0;
}
.arrow {
    transition: transform 0.3s;
    font-size: 12px;
}
.faq-item.active .arrow {
    transform: rotate(180deg);
}
