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

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 30px;
    padding: 30px 20px;
    background: #1a1a2e;
}

/* ---- Navigation ---- */

.top-nav {
    display: flex;
    gap: 6px;
    background: #252540;
    border-radius: 14px;
    padding: 5px;
}

.nav-link {
    padding: 10px 30px;
    border-radius: 10px;
    color: #9090b0;
    font-family: 'Inter', sans-serif;
    font-size: 0.95rem;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.2s ease;
}

.nav-link:hover {
    color: #e0e0ff;
    background: #2e2e50;
}

.nav-link.active {
    background: #7c3aed;
    color: #fff;
}

/* ---- Calculator ---- */

.calculator {
    display: grid;
    grid-template-columns: repeat(4, 85px);
    grid-template-rows: minmax(140px, auto) repeat(5, 85px);
    gap: 1px;
    background: #252540;
    border-radius: 24px;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4);
}

.display {
    grid-column: 1 / -1;
    background: #1e1e38;
    display: flex;
    align-items: flex-end;
    justify-content: flex-end;
    flex-direction: column;
    padding: 24px 28px;
    word-wrap: break-word;
    word-break: break-all;
    gap: 8px;
}

.display .previous-operand {
    color: #8888aa;
    font-size: 1.1rem;
    font-weight: 400;
    min-height: 1.4rem;
}

.display .current-operand {
    color: #ffffff;
    font-size: 2.8rem;
    font-weight: 300;
    min-height: 3.2rem;
}

.calculator > button {
    cursor: pointer;
    font-size: 1.4rem;
    font-family: 'Inter', sans-serif;
    font-weight: 400;
    border: none;
    outline: none;
    transition: all 0.15s ease;
}

.calculator > button:active {
    transform: scale(0.95);
}

.btn-number {
    background: #2a2a48;
    color: #ffffff;
}

.btn-number:hover {
    background: #353560;
}

.btn-function {
    background: #32325a;
    color: #c0c0e0;
    font-size: 1.15rem !important;
    font-weight: 500;
}

.btn-function:hover {
    background: #3d3d6a;
    color: #ffffff;
}

.btn-operator {
    background: #352a60;
    color: #c4b5fd;
    font-size: 1.6rem !important;
}

.btn-operator:hover {
    background: #40307a;
    color: #ddd0ff;
}

.btn-equals {
    background: #7c3aed;
    color: #ffffff;
    font-size: 1.8rem !important;
    font-weight: 500;
}

.btn-equals:hover {
    background: #8b5cf6;
}

.span-two {
    grid-column: span 2;
}

/* ---- Survey ---- */

.survey-card {
    width: 100%;
    max-width: 480px;
    background: #252540;
    border-radius: 24px;
    padding: 40px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4);
}

.survey-card h2 {
    color: #ffffff;
    font-size: 1.6rem;
    font-weight: 600;
    margin-bottom: 8px;
}

.survey-subtitle {
    color: #9090b0;
    font-size: 0.95rem;
    margin-bottom: 32px;
}

.form-group {
    margin-bottom: 22px;
}

.form-group label {
    display: block;
    color: #c0c0e0;
    font-size: 0.9rem;
    font-weight: 500;
    margin-bottom: 8px;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 12px 16px;
    background: #1e1e38;
    border: 1px solid #3a3a60;
    border-radius: 12px;
    color: #ffffff;
    font-family: 'Inter', sans-serif;
    font-size: 0.95rem;
    outline: none;
    transition: all 0.2s ease;
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: #6060880;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    border-color: #7c3aed;
    box-shadow: 0 0 0 3px rgba(124, 58, 237, 0.2);
}

.form-group select {
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='%23c0c0e0' viewBox='0 0 16 16'%3E%3Cpath d='M8 11L3 6h10l-5 5z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
}

.form-group select option {
    background: #252540;
    color: #ffffff;
}

.form-group textarea {
    resize: vertical;
    min-height: 80px;
}

.submit-btn {
    width: 100%;
    padding: 14px;
    border: none;
    border-radius: 12px;
    background: #7c3aed;
    color: #ffffff;
    font-family: 'Inter', sans-serif;
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    margin-top: 8px;
}

.submit-btn:hover {
    background: #8b5cf6;
    box-shadow: 0 4px 20px rgba(124, 58, 237, 0.3);
    transform: translateY(-1px);
}

.submit-btn:active {
    transform: translateY(0);
}
