* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: linear-gradient(135deg, #1f2937 0%, #000000 50%, #1f2937 100%);
    min-height: 100vh;
    color: white;
}

.container {
    max-width: 28rem;
    margin: 0 auto;
    background: rgba(17, 24, 39, 0.8);
    backdrop-filter: blur(10px);
    min-height: 100vh;
}

.header {
    background: linear-gradient(90deg, #9333ea 0%, #ec4899 50%, #3b82f6 100%);
    padding: 1.5rem;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.2);
}

.header-content {
    position: relative;
    z-index: 1;
}

.header h1 {
    font-size: 1.5rem;
    font-weight: bold;
    margin-bottom: 0.25rem;
}

.header p {
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.875rem;
}

.progress-bar {
    background: #1f2937;
    height: 4px;
}

.progress-fill {
    background: linear-gradient(90deg, #9333ea, #ec4899);
    height: 100%;
    transition: width 0.5s ease;
}

.content {
    padding: 1.5rem;
    padding-bottom: 8rem;
}

.step-container {
    display: none;
}

.step-container.active {
    display: block;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.step-header {
    text-align: center;
    margin-bottom: 2rem;
}

.step-icon {
    width: 5rem;
    height: 5rem;
    margin: 0 auto 1.5rem;
    border-radius: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3rem;
}

.step-title {
    font-size: 1.875rem;
    font-weight: bold;
    margin-bottom: 0.75rem;
}

.step-subtitle {
    color: #9ca3af;
    font-size: 1.125rem;
}

.form-group {
    margin-bottom: 1.5rem;
    text-align: center;
}

.form-label {
    display: block;
    text-align: center;
    font-weight: bold;
    font-size: 1.1rem;
    margin-bottom: 0.25rem;
    letter-spacing: 0.5px;
}

.input-helper {
    text-align: center;
    font-size: 1rem;
    margin-top: 0.1rem;
    font-weight: bold;
}

.label-weight { color: #38bdf8; }
.unit-kg     { color: #0ea5e9; }
.label-height{ color: #a78bfa; }
.unit-cm     { color: #7c3aed; }
.label-age   { color: #fbbf24; }
.unit-years  { color: #f59e42; }

.form-label {
    display: block;
    color: #9ca3af;
    font-size: 0.875rem;
    font-weight: 500;
    margin-bottom: 0.5rem;
    text-align: center;
}

.form-input {
    width: 100%;
    padding: 1rem;
    background: #1f2937;
    border: 1px solid #374151;
    border-radius: 1rem;
    color: rgb(255, 255, 255);
    font-size: 1rem;
    transition: all 0.3s ease;
}

.form-input:focus {
    outline: none;
    border-color: #9333ea;
    box-shadow: 0 0 0 2px rgba(147, 51, 234, 0.2);
}

.form-input::placeholder {
    color: #6b7280;
}

#weight.form-input {
    color: #0ea5e9;
    font-weight: bold;
    transition: color 0.2s;
}
#height.form-input {
    color: #7c3aed;
    font-weight: bold;
    transition: color 0.2s;
}
#age.form-input {
    color: #f59e42;
    font-weight: bold;
    transition: color 0.2s;
}

.input-grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.input-grid-3 {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 1rem;
}

.button-group {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.option-button {
    padding: 1.5rem;
    border-radius: 1rem;
    border: 2px solid #374151;
    background: rgba(31, 41, 55, 0.5);
    color: white;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: center;
}

.option-button:hover {
    border-color: #4b5563;
}

.option-button.selected {
    border-color: #9333ea;
    background: rgba(147, 51, 234, 0.1);
    box-shadow: 0 0 20px rgba(147, 51, 234, 0.2);
}

.option-button.selected.male {
    border-color: #3b82f6;
    background: rgba(59, 130, 246, 0.1);
    box-shadow: 0 0 20px rgba(59, 130, 246, 0.2);
}

.option-button.selected.female {
    border-color: #ec4899;
    background: rgba(236, 72, 153, 0.1);
    box-shadow: 0 0 20px rgba(236, 72, 153, 0.2);
}

.option-button.selected.activity {
    border-color: #10b981;
    background: rgba(16, 185, 129, 0.1);
    box-shadow: 0 0 20px rgba(16, 185, 129, 0.2);
}

.option-emoji {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
}

.option-title {
    font-weight: bold;
    color: #222;
}
.option-desc {
    color: #555;
}

.activity-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.activity-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    border-radius: 1rem;
    margin-bottom: 1rem;
    cursor: pointer;
    border: 2px solid transparent;
    background: #fff;
    transition: border-color 0.2s, box-shadow 0.2s, background 0.2s;
}

.activity-item[data-activity="sedentary"]:hover,
.activity-item[data-activity="sedentary"].active {
    border-color: #a1a1aa;
    background: #f4f4f5;
    box-shadow: 0 2px 12px 0 rgba(107,114,128,0.07);
}
.activity-item[data-activity="light"]:hover,
.activity-item[data-activity="light"].active {
    border-color: #60a5fa;
    background: #e0f2fe;
    box-shadow: 0 2px 12px 0 rgba(59,130,246,0.07);
}
.activity-item[data-activity="moderate"]:hover,
.activity-item[data-activity="moderate"].active {
    border-color: #34d399;
    background: #d1fae5;
    box-shadow: 0 2px 12px 0 rgba(16,185,129,0.07);
}
.activity-item[data-activity="active"]:hover,
.activity-item[data-activity="active"].active {
    border-color: #fbbf24;
    background: #fef9c3;
    box-shadow: 0 2px 12px 0 rgba(245,158,11,0.07);
}
.activity-item[data-activity="veryActive"]:hover,
.activity-item[data-activity="veryActive"].active {
    border-color: #f87171;
    background: #fee2e2;
    box-shadow: 0 2px 12px 0 rgba(239,68,68,0.07);
}

.activity-icon {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    line-height: 1;
    border-radius: 50%;
    background: #fff;
    color: #222;
    transition: border-color 0.2s;
}

.bodyfat-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.bodyfat-option {
    padding: 1.5rem;
    border-radius: 1rem;
    border: 2px solid #374151;
    background: rgba(31, 41, 55, 0.5);
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: center;
}

.bodyfat-option:hover {
    border-color: #4b5563;
}

.bodyfat-option.selected {
    border-color: #9333ea;
    background: rgba(147, 51, 234, 0.1);
    box-shadow: 0 0 20px rgba(147, 51, 234, 0.2);
}

.bodyfat-icon {
    font-size: 3rem;
    line-height: 1.1;
    display: flex;
    align-items: center;
    justify-content: center;
}

.bodyfat-range {
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.bodyfat-title {
    font-size: 0.875rem;
    font-weight: 500;
    margin-bottom: 0.25rem;
}

.bodyfat-desc {
    font-size: 0.75rem;
    color: #6b7280;
}

/* Colorize each body fat percentage section for outstanding view */
.bodyfat-option[data-bodyfat="13"] {
    background: rgba(147, 51, 234, 0.08);
    border-radius: 1rem;
}
.bodyfat-option[data-bodyfat="13"] .bodyfat-range,
.bodyfat-option[data-bodyfat="13"] .bodyfat-title {
    color: #9333ea;
    font-weight: bold;
}
.bodyfat-option[data-bodyfat="13"] .bodyfat-desc {
    color: #7c3aed;
}

.bodyfat-option[data-bodyfat="18"] {
    background: rgba(16, 185, 129, 0.08);
    border-radius: 1rem;
}
.bodyfat-option[data-bodyfat="18"] .bodyfat-range,
.bodyfat-option[data-bodyfat="18"] .bodyfat-title {
    color: #10b981;
    font-weight: bold;
}
.bodyfat-option[data-bodyfat="18"] .bodyfat-desc {
    color: #059669;
}

.bodyfat-option[data-bodyfat="23"] {
    background: rgba(59, 130, 246, 0.08);
    border-radius: 1rem;
}
.bodyfat-option[data-bodyfat="23"] .bodyfat-range,
.bodyfat-option[data-bodyfat="23"] .bodyfat-title {
    color: #3b82f6;
    font-weight: bold;
}
.bodyfat-option[data-bodyfat="23"] .bodyfat-desc {
    color: #2563eb;
}

.bodyfat-option[data-bodyfat="28"] {
    background: rgba(245, 158, 11, 0.08);
    border-radius: 1rem;
}
.bodyfat-option[data-bodyfat="28"] .bodyfat-range,
.bodyfat-option[data-bodyfat="28"] .bodyfat-title {
    color: #f59e0b;
    font-weight: bold;
}
.bodyfat-option[data-bodyfat="28"] .bodyfat-desc {
    color: #d97706;
}

.bodyfat-option[data-bodyfat="33"] {
    background: rgba(239, 68, 68, 0.08);
    border-radius: 1rem;
}
.bodyfat-option[data-bodyfat="33"] .bodyfat-range,
.bodyfat-option[data-bodyfat="33"] .bodyfat-title {
    color: #ef4444;
    font-weight: bold;
}
.bodyfat-option[data-bodyfat="33"] .bodyfat-desc {
    color: #b91c1c;
}

.bodyfat-option[data-bodyfat="38"] {
    background: rgba(55, 65, 81, 0.08);
    border-radius: 1rem;
}
.bodyfat-option[data-bodyfat="38"] .bodyfat-range,
.bodyfat-option[data-bodyfat="38"] .bodyfat-title {
    color: #374151;
    font-weight: bold;
}
.bodyfat-option[data-bodyfat="38"] .bodyfat-desc {
    color: #6b7280;
}

.review-card {
    background: rgba(31, 41, 55, 0.7);
    border-radius: 1.25rem;
    padding: 2rem 1.5rem;
    margin: 2rem 0;
    box-shadow: 0 4px 24px rgba(0,0,0,0.15);
    max-width: 420px;
    margin-left: auto;
    margin-right: auto;
}

.review-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}

.review-grid-single {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.review-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 1rem;
    border-radius: 0.75rem;
    background: rgba(55, 65, 81, 0.25);
    box-shadow: 0 1px 4px rgba(0,0,0,0.04);
}

.review-label {
    color: #a78bfa;
    font-weight: 600;
    font-size: 1.05rem;
    letter-spacing: 0.5px;
}

.review-value {
    color: #fbbf24;
    font-weight: 700;
    font-size: 1.08rem;
    letter-spacing: 0.5px;
}

.review-value-name {
    color: #38bdf8;      /* Sky Blue */
}
.review-value-gender {
    color: #f472b6;      /* Pink */
}
.review-value-age {
    color: #fbbf24;      /* Amber */
}
.review-value-weight {
    color: #0ea5e9;      /* Cyan */
}
.review-value-height {
    color: #a78bfa;      /* Violet */
}
.review-value-bodyfat {
    color: #f87171;      /* Red */
}
.review-value-activity {
    color: #10b981;      /* Green */
}

.review-divider {
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid #374151;
}

.results-timeline {
    background: linear-gradient(135deg, #9333ea, #ec4899);
    border-radius: 1.5rem;
    padding: 2rem;
    text-align: center;
    box-shadow: 0 25px 50px rgba(147, 51, 234, 0.3);
    margin-bottom: 1.5rem;
}

.results-icon {
    margin-bottom: 1rem;
    font-size: 2.5rem;
}

.results-number {
    font-size: 3.75rem;
    font-weight: bold;
    margin-bottom: 0.5rem;
}

.results-label {
    color: rgba(255, 255, 255, 0.8);
    font-size: 1.25rem;
    font-weight: 500;
    margin-bottom: 0.25rem;
}

.results-sublabel {
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.875rem;
}

.stats-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.stat-card {
    background: rgba(31, 41, 55, 0.5);
    backdrop-filter: blur(10px);
    border-radius: 1rem;
    padding: 1.5rem;
    border: 1px solid #374151;
}

.stat-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.stat-icon {
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 0.75rem;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 2.5rem;
}

.stat-title {
    color: white;
    font-weight: 600;
}

.stat-number {
    font-size: 1.875rem;
    font-weight: bold;
    color: white;
    margin-bottom: 0.25rem;
}

.stat-label {
    color: #9ca3af;
    font-size: 0.875rem;
}

.already-lean {
    background: linear-gradient(135deg, #10b981, #059669);
    border-radius: 1.5rem;
    padding: 2rem;
    text-align: center;
    box-shadow: 0 25px 50px rgba(16, 185, 129, 0.3);
}

.already-lean-emoji {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.already-lean-text {
    color: white;
    font-size: 1.25rem;
    font-weight: 500;
    margin-bottom: 1rem;
}

.already-lean-subtitle {
    color: rgba(255, 255, 255, 0.8);
}

.body-composition {
    background: rgba(31, 41, 55, 0.3);
    backdrop-filter: blur(10px);
    border-radius: 1rem;
    padding: 1.5rem;
    border: 1px solid #374151;
    margin-bottom: 1.5rem;
}

.composition-title {
    color: white;
    font-weight: 600;
    font-size: 1.125rem;
    margin-bottom: 1rem;
}

.composition-grid {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 1rem;
    text-align: center;
}

.composition-item .stat-number {
    font-size: 1.5rem;
}

.navigation {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    max-width: 28rem;
    margin: 0 auto;
    background: rgba(17, 24, 39, 0.95);
    backdrop-filter: blur(10px);
    border-top: 1px solid #1f2937;
    padding: 1rem;
}

.nav-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-button {
    padding: 0.75rem;
    border-radius: 1rem;
    background: none;
    border: none;
    color: #9ca3af;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.nav-button:hover:not(:disabled) {
    color: white;
    background: #1f2937;
}

.nav-button:disabled {
    color: #4b5563;
    cursor: not-allowed;
}

.nav-button.primary {
    background: linear-gradient(90deg, #9333ea, #ec4899);
    color: white;
    padding: 0.75rem 1.5rem;
    box-shadow: 0 10px 25px rgba(147, 51, 234, 0.25);
}

.nav-button.primary:disabled {
    background: #1f2937;
    color: #6b7280;
    box-shadow: none;
}

.nav-indicators {
    display: flex;
    gap: 0.5rem;
}

.nav-dot {
    width: 0.5rem;
    height: 0.5rem;
    border-radius: 50%;
    background: #374151;
    transition: background 0.3s ease;
}

.nav-dot.active {
    background: #9333ea;
}

.reset-button {
    width: 100%;
    background: linear-gradient(90deg, #374151, #1f2937);
    color: white;
    padding: 1rem 1.5rem;
    border-radius: 1rem;
    border: none;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
}

.reset-button:hover {
    background: linear-gradient(90deg, #4b5563, #374151);
}

.hidden {
    display: none;
}

.unit-kg {
    color: #0ea5e9;
}

.unit-cm {
    color: #7c3aed;
}

.unit-years {
    color: #f59e42;
}

.composition-current-bf {
    color: #f87171; /* Red */
}
.composition-target-bf {
    color: #10b981; /* Green */
}
.composition-lean-mass {
    color: #38bdf8; /* Sky Blue */
}

/* Timeline and Results */
.results-number-months {
    color: #38bdf8; /* Sky Blue */
}
.results-weeks {
    color: #f472b6; /* Pink */
}
.stat-number-loss {
    color: #ef4444; /* Red */
}
.stat-number-target {
    color: #10b981; /* Green */
}
.stat-number-calories {
    color: #f59e0b; /* Amber */
}
.stat-number-tdee {
    color: #9333ea; /* Violet */
}

/* Responsive Design */
@media (max-width: 480px) {
    .input-grid-3 {
        grid-template-columns: 1fr;
    }
    
    .bodyfat-grid {
        grid-template-columns: 1fr;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .composition-grid {
        grid-template-columns: 1fr;
    }
}

.developer-info {
    max-width: 350px;
    margin: 2rem auto 1.5rem auto;
    padding: 1.25rem 1rem;
    background: rgba(31,41,55,0.85);
    border-radius: 1.25rem;
    box-shadow: 0 2px 16px rgba(0,0,0,0.10);
    color: #fff;
    font-size: 1rem;
    text-align: left;
}
.developer-info h4 {
    color: #38bdf8;
    margin-bottom: 0.75rem;
    font-size: 1.15rem;
    font-weight: bold;
    text-align: center;
}
.developer-info a {
    color: #fbbf24;
    text-decoration: none;
    transition: color 0.2s;
    word-break: break-all;
}
.developer-info a:hover {
    color: #10b981;
}
.developer-info div {
    margin-bottom: 0.4rem;
}

.about-dev-btn {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    z-index: 9999;
    background: #2563eb;
    color: #fff;
    border: none;
    border-radius: 1rem;
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
    cursor: pointer;
    box-shadow: 0 4px 16px rgba(37,99,235,0.15);
    opacity: 0.85;
    transition: opacity 0.2s;
}
.about-dev-btn:hover {
    opacity: 1;
}

.developer-info-panel {
    position: fixed;
    bottom: 5.5rem;
    right: 2rem;
    z-index: 10000;
    background: #18181b;
    color: #fff;
    border-radius: 1.25rem;
    padding: 1.5rem 1.25rem 1.25rem 1.25rem;
    box-shadow: 0 8px 32px rgba(0,0,0,0.25);
    min-width: 270px;
    max-width: 350px;
    font-size: 1rem;
    text-align: left;
    animation: fadeIn 0.2s;
}
.developer-info-panel h4 {
    color: #38bdf8;
    margin-bottom: 0.75rem;
    font-size: 1.15rem;
    font-weight: bold;
    text-align: center;
}
.developer-info-panel a {
    color: #fbbf24;
    text-decoration: none;
    transition: color 0.2s;
    word-break: break-all;
}
.developer-info-panel a:hover {
    color: #10b981;
}
.developer-info-panel div {
    margin-bottom: 0.4rem;
}
.developer-info-panel.hidden {
    display: none;
}
.close-dev-panel {
    position: absolute;
    top: 0.5rem;
    right: 1rem;
    background: none;
    border: none;
    color: #fff;
    font-size: 1.5rem;
    cursor: pointer;
    opacity: 0.7;
    transition: opacity 0.2s;
}
.close-dev-panel:hover {
    opacity: 1;
}