/* ==========================================================================
   FORM FIT - Create Account and Create Support Ticket forms (layout only)

   Fields used to be sized from the screen (`width: calc(100vw - 40px)`) while
   buttons filled the form, so they only lined up at some screen widths.
   Here every field and button in a `form.uw-form-fit` fills the form's width
   (border included), so they are the same width on every phone and tablet.

   `body:not(#_f)` makes these rules beat `body.glass:not(#_g) ...` in
   theme-glass.css and `body.light ...` in index.css, whatever theme is active.
   ========================================================================== */

body:not(#_f) form.uw-form-fit .input-element,
body:not(#_f) form.uw-form-fit .button {
    box-sizing: border-box !important;
    width: 100% !important;
    max-width: 100% !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
}

body:not(#_f) form.uw-form-fit .input-element {
    display: block;
    /* 16px stops iOS Safari from zooming the page when a field is tapped */
    font-size: 16px;
}

/* file picker: keep the "Choose Files" button off the border */
body:not(#_f) form.uw-form-fit input[type="file"].input-element {
    height: auto !important;
    min-height: 40px;
    padding: 7px 8px !important;
    font-size: 14px;
}

/* ==========================================================================
   ADD SYMBOL SEARCH BAR (.ss-search) - keep the close (x) icon inside the field

   The x was placed with a negative margin sized for a 40px-high field that ends
   51px from the screen edge, so with the glass theme (36px field, different
   width) it sat half outside the field's right edge and below its centre.
   The field now fills the bar (10px gap each side) and both icons are placed
   inside it and centred on it, for every theme and screen width.
   The x is still shown/hidden by the app's JS (inline display), as before.
   ========================================================================== */

body:not(#_f) .ss-search {
    position: relative;
    padding: 10px;
}

body:not(#_f) .ss-search .ss-searchin.input-element {
    display: block;
    box-sizing: border-box;
    width: 100% !important;
    max-width: none;
    margin: 0;
    padding-right: 44px;
}

body:not(#_f) .ss-search .ss-search-icon,
body:not(#_f) .ss-search .ss-search-close-icon {
    position: absolute;
    top: 10px;
    margin: 0 !important;
    height: 40px;
    line-height: 40px;
}

body:not(#_f) .ss-search .ss-search-icon {
    left: 20px;
}

body:not(#_f) .ss-search .ss-search-close-icon {
    right: 14px;
    width: 36px;
    text-align: center;
}

/* glass theme: the field is 36px high */
body.glass:not(#_f) .ss-search .ss-search-icon,
body.glass:not(#_f) .ss-search .ss-search-close-icon {
    height: 36px;
    line-height: 36px;
}

/* ==========================================================================
   ADD SYMBOL STRIKE LIST (.strike-row-modern) - strike price readable in both themes

   .strike-price-val was always #ffffff with no light-theme colour, so in the
   light theme it was white on a white row (invisible). It now uses the theme's
   text colour (black on light, white on dark) and the same size/weight as the
   symbol name, with even-width digits so the strikes line up.
   ========================================================================== */

body:not(#_f) .strike-row-modern .strike-price-val {
    color: #ffffff;
    font-size: 15px;
    font-weight: 600;
    font-variant-numeric: tabular-nums;
}

body.light:not(#_f) .strike-row-modern .strike-price-val {
    color: #000000;
}

/* glass theme (default): its own text colour for light/dark */
body.glass:not(#_f) .strike-row-modern .strike-price-val {
    color: var(--g-text);
}
