/* Base Mobile Styles */
body {
    margin: 0;
    font-family: sans-serif;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}
.medicalPage
{
    /*background-color:#CCC9C8; */  
}

.container {
    padding: 15px;
    flex: 1;
}

/* Header Grid/Flex for Mobile Layout */
#site_header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 20px;
    border-bottom: 1px solid #ccc;
    position: relative; /* Anchor for mobile dropdown */
}
/******************/
/*
#site_header_title {
    font-size: 1.5rem;
    font-weight: bold;
}
*/

#site_header_title {
    display: inline-flex !important;
    align-items: center !important; /* Centers back arrow, text, and logo perfectly on the same line */
    justify-content: flex-start !important;
    gap: 50px; /* Clean spacing between arrow, text, and the logo image */
    font-family: -apple-system, BlinkMacSystemFont, sans-serif;
    font-size: 1.5rem;
    font-weight: 700;
    color: #1e293b;
    white-space: nowrap !important; /* Strictly blocks text wrapping under tight sizing scaling */
}
/* Ensure the SVG back-arrow remains perfectly centered as an inline container */
#site_header_title .back-link {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    vertical-align: middle !important;
    margin: 0 10px !important;
}
/* THE INLINE IMAGE ALIGNMENT FIX */
#contextIcon {
    display: inline-block !important;
    vertical-align: middle !important; /* Eliminates the default browser text-baseline descender gap */
    object-fit: contain !important;
    margin: 0 !important; /* Wipes stray structural block margins */
    height: auto !important; /* Automatically preserves aspect ratio based on your width="40" attribute */
}
/******************/

/* Hamburger Icon Styling */
#menu_toggle {
    display: flex;
    flex-direction: column;
    justify-content: space-around;
    width: 30px;
    height: 24px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0;
    z-index: 10;
}

#menu_toggle span {
    width: 30px;
    height: 3px;
    background-color: #333;
    transition: all 0.3s ease;
}

/* Transform Hamburger into an 'X' when active */
#menu_toggle.active span:nth-child(1) { transform: rotate(45deg) translate(5px, 5px); }
#menu_toggle.active span:nth-child(2) { opacity: 0; }
#menu_toggle.active span:nth-child(3) { transform: rotate(-45deg) translate(6px, -6px); }

/* Hidden Mobile Menu */
#site_header_menu {
    display: none; 
    /*flex-direction: column;*/
    /*
    flex-wrap: wrap;
    justify-content: flex-start;
    */
    gap: 10px;
    text-align: center;
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    background-color: #fff;
    padding: 15px 0;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

/* Show Mobile Menu when Active */
#site_header_menu.active {
    display: flex;
}

#site_header_menu a {
    display: block;
    padding: 12px;
    background-color: #f9f9f9;
    text-decoration: none;
    color: #333;
}

#site_content {
    padding: 20px 0;
}

#my_home_outer 
{
   /* background-color: #f8fafc; *//* Light canvas color from the image */
    padding: 30px;
    border-radius: 8px;
}

footer {
    text-align: center;
    padding: 15px;
    background-color: #333;
    color: #fff;
    margin-top: auto;
}
/* page summary stuff 
.sleep-compact-summary-row, .oxygen-sleep-card-summary, .steps-card-summary
{
    font-family: -apple-system, BlinkMacSystemFont, sans-serif !important;
    font-size: 0.88rem !important;
}
*/



/* Tablet and Desktop Styles */
@media (min-width: 768px) {
    .container {
        max-width: 1200px;
        margin: 0 auto;
        width: 100%;
        box-sizing: border-box;
    }

    /* Hide the burger menu on desktop */
    #menu_toggle {
        display: none;
    }

    /* Reset navigation position for desktop */
    #site_header_menu {
        display: flex;
        flex-direction: row;
        position: static;
        width: auto;
        box-shadow: none;
        padding: 0;
        gap: 20px;
    }

    #site_header_menu a {
        display: inline;
        padding: 0;
        background-color: transparent;
    }
}

#users_home_outer
{
    padding:10px;
    border:thin solid grey;
    border-radius:20px;
}

/* ==========================================================================
   MOBILE BOUNDARIES RESPONSIVE ADJUSTMENT FOR GLOBAL DATE PICKER
   ========================================================================== */
.home-navigator-override {
    display: flex !important;
    flex-wrap: wrap !important; /* THE FIX: Allows children to drop to a second row on tight viewports */
    justify-content: center !important;
    align-items: center !important;
    gap: 8px !important; /* Maintains clean item grid margins */
    max-width: 100% !important;
    box-sizing: border-box !important;
}

/* Ensure the native date picker remains flexible on smartphone screens */
.home-navigator-override .active-date-input {
    max-width: 135px !important; /* Prevents the browser from expanding the calendar input box */
    font-size: 0.88rem !important;
    text-align: center !important;
}

/* Mobile Constraint Threshold overrides */
@media (max-width: 480px) {
    .dashboard-header-panel {
        padding: 0 4px !important;
        box-sizing: border-box !important;
    }

    .home-navigator-override {
        padding: 8px 12px !important; /* Compresses internal panel padding space */
        border-radius: 16px !important; /* Keeps layout styles crisp */
    }

    /* Streamlines the action pill buttons for smaller screen clearances */
    /*
	.home-navigator-override .btn-pill {
        padding: 6px 10px !important;
        font-size: 0.82rem !important;
    }
	*/
}


/* ==========================================================================
   9. GLOBAL UTILITY BUTTONS (SITE-WIDE)
   ========================================================================== */
.btn-pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background-color: #f1f5f9;
    color: #334155; 
    text-decoration: none; 
    font-size: 0.9rem;
    font-weight: 600;
    /*text-transform: uppercase;*/
    letter-spacing: 0.05em;
    padding: 8px 18px;
    border-radius: 20px; 
    border: 1px solid #e2e8f0;
    cursor: pointer;
    transition: all 0.2s ease-in-out;
}

/* Hover and Tap States */
.btn-pill:hover,
.btn-pill:active {
    background-color: #e2e8f0; 
    color: #0f172a; 
    border-color: #cbd5e1;
    transform: translateY(-1px); 
}

/* Container layout to align navigation elements side-by-side */
/*
.date-navigator {
    display: inline-flex;
    align-items: center;
    gap: 16px; 
}
*/

/* Base style for the active date display */
/*
.active-date {
    font-size: 1rem;
    font-weight: 600;
    color: #334155; /
}
*/

/* ==========================================================================
   GLOBAL RESPONSIVE DATE NAVIGATOR CONTAINER STYLES
   ========================================================================== */
.date-navigator-day-label
{
    font-weight:normal;
    font-size:0.8em !important;
}

.date-navigator {
    display: inline-flex !important;
    flex-direction: row !important;
    /* 🟢 THE GLOBAL FIX: Permits clean button wrapping across all site modules */
    flex-wrap: wrap !important; 
    align-items: center !important;
    justify-content: center !important;
    gap: 8px !important; /* Uniform gap stops elements colliding when wrapping */
    
    background-color: #ffffff !important;
    border: 0px solid #cbd5e1 !important;
    border-radius: 24px !important;
    padding: 6px 12px !important;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.02) !important;
    
  /*  width: auto !important;*/
    max-width: 100% !important; /* Strict ceiling prevents container overflow */
    box-sizing: border-box !important;
}

/* Enforce fluid constraint tracking on the native date picker box input */
.date-navigator .active-date-input {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif !important;
    font-size: 0.9rem !important;
    font-weight: 600 !important;
    color: #1e293b !important;
    border: none !important;
    outline: none !important;
    background: transparent !important;
    cursor: pointer !important;
    max-width: 135px !important; /* Blocks native browser input expansion bugs */
    text-align: center !important;
}

/* Mobile Constraint Threshold Overrides */
@media (max-width: 480px) {
    .date-navigator {
        padding: 8px 10px !important; /* Compresses padding for low-profile screens */
        border-radius: 16px !important;
        width: 100% !important; /* Fills parent width safely on phones */
    }

    .date-navigator .btn-pill {
        padding: 6px 10px !important;
       /* font-size: 0.82rem !important;*/
        white-space: nowrap !important;
    }
}






/* Navigation specific pill overrides */
.btn-nav {
    font-size: 1.25rem; /* Scales up the arrows for better visibility */
    padding: 8px 14px;  /* Slightly narrower padding to keep them looking circular/balanced */
    line-height: 1;
}

/* Disabled state when user hits today's date boundary */
.btn-nav.disabled {
    background-color: #f8fafc; /* Lighter, washed out background */
    color: #94a3b8;            /* Muted slate text */
    border-color: #f1f5f9;
    cursor: not-allowed;
    opacity: 0.6;
    pointer-events: none;      /* Stops clicks completely on touch devices */
    transform: none !important; /* Prevents lift movement on hover */
}

/* Styling specific to the text-based Today pill */
.btn-today {
    /*font-size: 0.8rem;*/
    padding: 8px 14px;
    margin-left: 8px; /* Separates the reset utility from the core directional arrows */
}

.btn-today.disabled {
    background-color: #f8fafc;
    color: #94a3b8;
    border-color: #f1f5f9;
    pointer-events: none;
}

/* ==========================================================================
   UNIFIED GENERIC HISTORY MODULE PRINT TRIGGER BUTTON
   ========================================================================== */
.btn-print-report {
    font-family: inherit;
    /*font-size: 0.85rem;*/
    font-weight: 600;
    color: #475569; /* Slate Gray text look */
    background-color: #ffffff;
    border: 1px solid #cbd5e1 !important;
    padding: 7px 14px;
    border-radius: 8px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: all 0.15s ease-in-out;
    margin-left: auto;*/ /* Aligns button to the right of filter rows */
}

.btn-print-report:hover {
    color: #0f172a;
    background-color: #f8fafc;
    border-color: #94a3b8 !important;
}

/* Enforces hidden behavior inside the browser print stream engine layout */
@media print {
    .btn-print-report {
        display: none !important;
    }
}

/*************** site hesder nav-pills-link *********************************/

/* ==========================================================================
   SIMPLE CLEAN RE-USE COMPONENT: STANDARD NAV BUTTON PILLS
   ========================================================================== */
.nav-pills-link {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 140px !important;            /* Enforces identical standard width */
    min-height: 38px !important;
    padding: 10px 0 !important;         /* Consistent vertical thickness */
    border-radius: 24px !important;     /* Smooth capsule profile shape */
    border: 1px solid #cbd5e1 !important;
    background-color: #ffffff !important;
    color: #334155 !important;          /* Slate charcoal text color */
    font-size: 0.9rem !important;
    font-weight: 600 !important;
    line-height: 1 !important;          /* Perfectly centers text vertically */
    text-decoration: none !important;
    white-space: nowrap !important;     /* Stops text wrapping onto double lines */
    box-sizing: border-box !important;
    transition: background-color 0.1s ease-in-out, border-color 0.1s ease-in-out !important;
}

/* Hover Interaction State */
.nav-pills-link:hover {
    background-color: #f1f5f9 !important;
    border-color: #94a3b8 !important;
    color: #0f172a !important;
}

/* Tactile Click Feedback */
.nav-pills-link:active {
    transform: scale(0.98) !important;
}


/***************** chart summary header badgw *************/
/* Unified Top Dashboard Chart Page Metrics Summary Banners */
.chart-summary-header-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background-color: #fafafa;
    border: 1px solid #e2e8f0;
    padding: 8px 16px;
    border-radius: 8px;
    margin-top: 14px;
    margin-bottom: 2px;
    font-size: 0.9rem;
}

@media (max-width: 480px) {
    .chart-summary-header-badge {
        display: flex;
        flex-direction: column;
        align-items: flex-start;
        gap: 4px;
        padding: 10px 14px;
    }
}

.chart-summary-header-badge .summary-title {
    font-weight: 700;
    text-transform: uppercase;
    font-size: 0.76rem;
    letter-spacing: 0.02em;
}

.chart-summary-header-badge .summary-data {
    color: #0f172a;
    font-weight: 500;
}

.chart-summary-header-badge .summary-data strong {
    font-variant-numeric: tabular-nums;
    font-weight: 700;
}

/****************** backlink ************************************/
/* ==========================================================================
   Dedicated Standalone Dashboard Action Back Link
   ========================================================================== */

.back-link {
    display: inline-flex; /* Crucial: Allows the container box to hold the SVG geometry size */
    align-items: center;
    justify-content: center;
    width: 34px;          /* Ensure the button wrapper has clear structural dimensions */
    height: 34px;
    background-color: #f8fafc;
    border: 1px solid #cbd5e1;
    border-radius: 50%;   /* Gives the button a clean circular look matching your icon image */
    box-sizing: border-box;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Ensure the SVG path lines are visible */
.back-link .back-link-icon {
    display: block !important; /* Overrides any display: none or accidental hidden parameters */
    width: 18px !important;    /* Force the physical render box size */
    height: 18px !important;
    stroke: #475569 !important; /* Force the slate-grey line color explicitly */
}

/* Hover Interactive Action Feedback States */
.back-link:hover {
    background-color: #ffffff;
    border-color: #94a3b8;
}

.back-link:hover .back-link-icon {
    stroke: #1e293b !important; /* Intensifies the arrow line contrast to dark charcoal */
    transform: scale(1.05);     /* Gives a subtle popping animation cue on mouseover */
}

/* 02 display */
/*
O<subOxy>2</sub>
*/
sub-oxy {
  font-size: 75%; /* Scales the subscript down */
  vertical-align: sub; /* Aligns the text to the subscript baseline */
  line-height: 0; /* Prevents the subscript from altering the line height */
}


/* 5. Minimal Plain Text Actions Links Navigation Layer */
/****  taken from history_table_css *****/
.telemetry-text-link {
    color: #475569;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.82rem;
    border-bottom: 1px solid #cbd5e1;
    padding-bottom: 1px;
    transition: all 0.15s ease-in-out;
}
.telemetry-text-link:hover {
    color: #0f172a;
    border-bottom-color: #0f172a;
}

.telemetry-delete-link {
    color: #94a3b8;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.82rem;
    border-bottom: 1px dashed #cbd5e1;
    padding-bottom: 1px;
    transition: all 0.15s ease-in-out;
}
.telemetry-delete-link:hover {
    color: #ef4444;
    border-bottom: 1px solid #ef4444;
}

.telemetry-delete-button {
    background: none;
    border: none;
    color: #94a3b8;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.82rem;
    border-bottom: 1px dashed #cbd5e1;
    padding: 0 0 1px 0;
    margin: 0;
    cursor: pointer;
    transition: all 0.15s ease-in-out;
    font-family: inherit;
}

.telemetry-delete-button:hover {
    color: #ef4444;
    border-bottom: 1px dashed #ef4444;
}

.telemetry-delete-button:focus {
    outline: none;
}



.steps-del-link
{
    margin-left: 5px;
}
.weight-edit-link, .self-review-link
{
    margin-left: 10px;
    margin-right:10px;
}


.telemetry-no-data-alert {
    color: #475569;
    background-color: #f8fafc;
    border: 1px dashed #cbd5e1;
    padding: 24px;
    border-radius: 8px;
    text-align: center;
    font-style: italic;
}

