    /* Base Styling from jeff.css and added enhancements for layout */
    :root {
        --color-text-secondary: #764ba2;
        --font-mono: 'Inter', monospace;
        --spacing-sm: 5px;
    }

    /* General Reset and Base */
    * {
        margin: 0;
        padding: 0;
        box-sizing: border-box;
    }

    body {
        font-family: 'Inter', Tahoma, Geneva, Verdana, sans-serif;
        background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
        min-height: 100vh;
        display: flex;
        justify-content: center;
        align-items: center;
        padding: 10px;
    }

    /* Container - main card */
    .container {
        background: white;
        border-radius: 12px;
        padding: 15px;
        box-shadow: 0 5px 20px rgba(0, 0, 0, 0.3);
        max-width: 500px;
        width: 100%;
    }

    /* Headings and Subtitle */
    h1 {
        color: #333;
        margin-bottom: 2px;
        font-size: clamp(18px, 5vw, 24px);
        font-weight: 700;
    }

    .subtitle {
        color: #666;
        margin-bottom: 12px;
        font-size: clamp(12px, 3vw, 14px);
    }

    /* Input Group Sections */
    .input-section {
        background: #f8f9fa;
        border-radius: 8px;
        padding: 10px;
        margin-bottom: 10px;
    }

    .input-section h3 {
        color: #667eea;
        margin-bottom: 5px;
        font-size: clamp(14px, 3.5vw, 16px);
        font-weight: 600;
    }

    /* Input Rows */
    .input-row {
        display: flex;
        gap: 8px;
        margin-bottom: 5px;
        flex-wrap: nowrap;
        align-items: flex-end;
    }

    .input-field {
        flex: 1;
        min-width: 0; /* Allow shrinking below content size */
    }

    /* Radio button container */
    .radio-group {
        flex: 1;
        min-width: 0;
    }

    .radio-group label.main-label {
        display: block;
        color: #555;
        margin-bottom: 2px;
        font-size: clamp(10px, 2.5vw, 12px);
        font-weight: 600;
    }

    .radio-options {
        display: flex;
        gap: 15px;
        align-items: center;
        height: 30px;
        padding: 0 8px;
    }

    .radio-option {
        display: flex;
        align-items: center;
        gap: 5px;
    }

    .radio-option input[type="radio"] {
        width: auto;
        margin: 0;
        cursor: pointer;
    }

    .radio-option label {
        color: #555;
        font-size: clamp(12px, 3vw, 14px);
        font-weight: 500;
        cursor: pointer;
        margin: 0;
    }

    /* Labels and Inputs */
    label {
        display: block;
        color: #555;
        margin-bottom: 2px;
        font-size: clamp(10px, 2.5vw, 12px);
        font-weight: 600;
        white-space: nowrap;
        text-overflow: ellipsis;
    }

    /* Stepper Styles */
    .input-stepper {
        display: flex;
        width: 100%;
        border: 1px solid #e0e0e0;
        border-radius: 4px;
        overflow: hidden;
        background-color: white;
    }

    .input-stepper input {
        border: none;
        padding: 4px 6px;
        text-align: center;
        flex-grow: 1;
        font-size: clamp(12px, 3vw, 14px);
        min-width: 0;
        font-family: var(--font-mono);
    }
    /* Override for ageGrade input to allow text input without breaking stepper alignment */
    #ageGrade {
        padding-right: 2px; /* Small adjustment */
    }


    .input-stepper button {
        display: block;
        background: #e9ecef;
        border: none;
        width: 25px;
        min-width: 20px;
        padding: 0;
        cursor: pointer;
        font-size: clamp(14px, 4vw, 18px);
        line-height: 1;
        color: #555;
        transition: background 0.2s;
        /* Override display: none in original CSS */
        display: flex !important; 
        justify-content: center;
        align-items: center;
        height: 30px;
    }

    .input-stepper button:hover {
        background: #dee2e6;
    }

    .input-stepper button:first-child {
        border-right: 1px solid #e0e0e0;
    }

    .input-stepper button:last-child {
        border-left: 1px solid #e0e0e0;
    }

    /* General Inputs */
    input:not(.pace-input):not(.time-input),
    select {
        width: 100%;
        padding: 5px;
        border: 1px solid #e0e0e0;
        border-radius: 4px;
        font-size: clamp(12px, 3vw, 14px);
        transition: border-color 0.3s;
        font-family: 'Inter', sans-serif;
        background-color: white;
    }

    input:focus,
    select:focus {
        outline: none;
        border-color: #667eea;
        box-shadow: 0 0 0 1px #667eea;
    }
    
    /* Result Section (Age Grade) */
    .result {
        margin-top: 10px;
        padding: 15px;
        background: linear-gradient(135deg, #764ba2 0%, #667eea 100%);
        border-radius: 8px;
        color: white;
        text-align: center;
    }

    .result h2 {
        margin-bottom: 10px;
        font-size: clamp(14px, 4vw, 18px);
    }
    
    /* This is the input field now - REVERTED STYLING */
    #ageGradeResultContainer input {
        font-size: clamp(24px, 7vw, 32px);
        font-weight: 700;
        letter-spacing: 1px;
        color: #333; /* Dark text to sit on the white stepper background */
        text-shadow: none; /* Removed text shadow */
        background: white; /* White background to match the stepper container */
    }

    /* Two-way Stepper for Age Grade - REVERTED STYLING */
    #ageGradeStepper {
        width: 90%;
        max-width: 250px;
        margin: 5px auto 0; /* Added margin-top for spacing */
        /* Inherits default .input-stepper styles for border and background */
    }
    
    /* Projections Section */
    .projections {
        display: flex;
        gap: 10px;
        margin-top: 15px;
        flex-wrap: nowrap;
    }

    .projection-table {
        flex: 1;
        min-width: 0; /* Allow shrinking */
        background: #f0f0f5;
        padding: 10px;
        border-radius: 8px;
        box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    }

    .projection-table h2 {
        margin-bottom: 0px;
        color: #764ba2;
        font-size: clamp(14px, 4vw, 18px);
        text-align: center;
    }

    .projection-table h4 {
        font-size: clamp(11px, 3vw, 14px);
        color: #764ba2;
        margin-bottom: 8px;
        text-align: center;
        border-bottom: 1px solid #ddd;
        padding-bottom: 5px;
    }

    .projection-table table {
        width: 100%;
        border-collapse: collapse;
        font-size: clamp(10px, 2.5vw, 12px);
    }

    .projection-table th, .projection-table td {
        padding: 5px 3px;
        text-align: left;
        border-bottom: 1px dashed #e0e0e0;
    }

    .projection-table th {
        font-weight: 600;
        color: #333;
        background-color: #e5e5f0;
    }

    .projection-table td {
        font-family: var(--font-mono);
        font-weight: 500;
        color: #444;
    }

    /* Responsive adjustments for very small screens */
    @media (max-width: 400px) {
        .container {
            padding: 10px;
        }

        .input-section {
            padding: 8px;
        }

        .projection-table {
            padding: 8px;
        }

        .projection-table th, .projection-table td {
            padding: 4px 2px;
        }

        .input-stepper button {
            width: 20px;
            min-width: 18px;
        }
    }

    /* For extra small screens, allow minimal stacking only if absolutely necessary */
    @media (max-width: 320px) {
        .input-row {
            gap: 6px;
        }

        h1 {
            font-size: 16px;
        }

        .subtitle {
            font-size: 11px;
        }
    }