/* CalWhat Calculator Platform - ChildrenGrowthCalculator Specific Styles */
/* This file contains calculator-specific styles */

    .input-group-custom {
        margin-bottom: 12px;
    }

    .input-label {
        font-weight: 500;
        color: #4a5568;
        margin-bottom: 8px;
        display: flex;
        align-items: center;
        gap: 8px;
        font-size: 0.95rem;
        position: relative;
    }

    .tooltip-icon {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        width: 18px;
        height: 18px;
        border-radius: 50%;
        background: #667eea;
        color: white;
        font-size: 0.7rem;
        cursor: help;
        margin-left: 5px;
        position: relative;
    }

    .tooltip-icon:hover .tooltip-text {
        visibility: visible;
        opacity: 1;
    }

    .tooltip-text {
        visibility: hidden;
        opacity: 0;
        position: absolute;
        z-index: 1000;
        bottom: 125%;
        left: 50%;
        transform: translateX(-50%);
        background-color: #2d3748;
        color: white;
        text-align: center;
        padding: 8px 12px;
        border-radius: 8px;
        font-size: 0.85rem;
        white-space: nowrap;
        transition: opacity 0.3s;
        box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
        font-weight: 400;
    }

    .tooltip-text::after {
        content: "";
        position: absolute;
        top: 100%;
        left: 50%;
        margin-left: -5px;
        border-width: 5px;
        border-style: solid;
        border-color: #2d3748 transparent transparent transparent;
    }

    .input-wrapper {
        position: relative;
    }

    .form-input, .form-select {
        width: 100%;
        padding: 10px 12px;
        border: 2px solid #48bb78;
        border-radius: 12px;
        font-size: 1rem;
        font-family: 'Roboto Mono', monospace;
        transition: all 0.3s ease;
        background: #f0fff4;
    }

        .form-input:focus, .form-select:focus {
            outline: none;
            border-color: #38a169;
            box-shadow: 0 0 0 4px rgba(72, 187, 120, 0.2);
            transform: translateY(-2px);
        }

    .input-range {
        font-size: 0.75rem;
        color: #2d3748;
        margin-top: 4px;
    }

    .form-input.error {
        border-color: #ef4444;
        animation: shake 0.5s ease;
    }

    @keyframes shake {
        0%, 100% {
            transform: translateX(0);
        }

        25% {
            transform: translateX(-10px);
        }

        75% {
            transform: translateX(10px);
        }
    }

    .input-row {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }

    @media (max-width: 768px) {
        .input-row {
            grid-template-columns: 1fr;
        }
    }

    .result-card {
        background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
        color: white;
    }

    @media (min-width: 992px) {
        .result-card {
            position: sticky;
            top: 20px;
        }
    }

    .result-main {
        text-align: center;
        padding: 20px 0;
    }

    .result-label {
        font-size: 1.2rem;
        font-weight: 500;
        opacity: 0.95;
        margin-bottom: 10px;
    }

    .result-value {
        font-family: 'Roboto Mono', monospace;
        font-size: 3rem;
        font-weight: 700;
        margin-bottom: 30px;
        animation: pulse 0.5s ease;
    }

    @keyframes pulse {
        0%, 100% {
            transform: scale(1);
        }

        50% {
            transform: scale(1.05);
        }
    }

    .result-divider {
        border: 0;
        height: 2px;
        background: rgba(255, 255, 255, 0.3);
        margin: 20px 0;
    }

    .result-details {
        background: rgba(255, 255, 255, 0.1);
        border-radius: 12px;
        padding: 12px;
        margin-top: 15px;
    }

    .result-item {
        display: flex;
        justify-content: space-between;
        padding: 6px 0;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    }

        .result-item:last-child {
            border-bottom: none;
        }

    .result-item-label {
        font-size: 0.9rem;
        opacity: 0.9;
    }

    .result-item-value {
        font-family: 'Roboto Mono', monospace;
        font-weight: 600;
    }

    .chart-container {
        position: relative;
        height: 350px;
        margin: 10px 0;
    }


    @keyframes fadeInDown {
        from {
            opacity: 0;
            transform: translateY(-30px);
        }

        to {
            opacity: 1;
            transform: translateY(0);
        }
    }

    @media (max-width: 768px) {
        .page-header h1 {
            font-size: 2rem;
        }

        .result-value {
            font-size: 2rem;
        }

        .glass-card {
            padding: 20px;
        }
    }

    .spinner {
        display: none;
        border: 3px solid rgba(255, 255, 255, 0.3);
        border-top: 3px solid white;
        border-radius: 50%;
        width: 20px;
        height: 20px;
        animation: spin 1s linear infinite;
    }

    @keyframes spin {
        0% {
            transform: rotate(0deg);
        }

        100% {
            transform: rotate(360deg);
        }
    }

    .loading .spinner {
        display: inline-block;
    }

    .percentile-badge {
        display: inline-block;
        padding: 4px 12px;
        border-radius: 20px;
        font-size: 0.85rem;
        font-weight: 600;
        margin-left: 8px;
    }

    .badge-normal {
        background: #48bb78;
        color: white;
    }

    .badge-low {
        background: #f59e0b;
        color: white;
    }

    .badge-very-low {
        background: #ef4444;
        color: white;
    }

    .badge-high {
        background: #3b82f6;
        color: white;
    }

    .badge-very-high {
        background: #8b5cf6;
        color: white;
    }

    .tip-box {
        background: #fef3c7;
        border-left: 4px solid #f59e0b;
        padding: 12px 16px;
        border-radius: 8px;
        margin: 10px 0;
        font-size: 0.9rem;
        color: #92400e;
    }