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

html, body {
    height: 100%;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", system-ui, sans-serif;
    background: #0f1013;
    color: #ffffff;
    -webkit-font-smoothing: antialiased;
}

.app {
    min-height: 100vh;
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.app-header {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.app-title {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 700;
    font-size: 22px;
}

.app-emoji {
    font-size: 24px;
}

.app-subtitle {
    font-size: 13px;
    color: #9ea3b5;
}

.app-main {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.card {
    background: linear-gradient(135deg, #191b22, #15161c);
    border-radius: 18px;
    padding: 14px 14px 12px;
    box-shadow: 0 14px 30px rgba(0, 0, 0, 0.45);
    border: 1px solid rgba(255, 255, 255, 0.03);
}

.card h2 {
    font-size: 16px;
    margin-bottom: 10px;
}

.range-row {
    display: flex;
    gap: 8px;
    margin-bottom: 10px;
}

input[type="number"],
input[type="text"] {
    flex: 1;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    background: rgba(12, 13, 18, 0.9);
    padding: 8px 10px;
    font-size: 14px;
    color: #ffffff;
    outline: none;
    -webkit-appearance: none;
}

input::placeholder {
    color: #686d7f;
}

.btn {
    border: none;
    border-radius: 999px;
    padding: 8px 16px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    outline: none;
    transition: transform 0.12s ease-out, box-shadow 0.12s ease-out, background 0.12s ease-out;
    -webkit-tap-highlight-color: transparent;
}

.btn:active {
    transform: scale(0.96);
}

.btn.primary {
    width: 100%;
    background: radial-gradient(circle at 0 0, #3f6df6, #6a4df5);
    color: #ffffff;
    box-shadow: 0 10px 24px rgba(79, 119, 255, 0.45);
}

.btn.secondary {
    background: rgba(255, 255, 255, 0.06);
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.result {
    margin-top: 8px;
    font-size: 18px;
    font-weight: 600;
    min-height: 22px;
}

.result span {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.06);
}

.result.animate {
    animation: pop 0.28s ease-out;
}

@keyframes pop {
    0%   { transform: scale(0.6); opacity: 0; }
    70%  { transform: scale(1.06); opacity: 1; }
    100% { transform: scale(1.0); opacity: 1; }
}
