/*
 * Da Vat Hy Lures — Phase 24B.2.6C
 * My Waters — Full-Width Home-Style Band Corrective
 *
 * STYLE ONLY.
 * Replaces the remaining left-intro / right-working-card architecture with
 * the same one-column full-width section rhythm used across the public Home.
 */

@media(min-width:901px){

  /* The secondary My Waters section is normally hidden on Today until targeted.
     When opened, let it become a true page band rather than a dashboard inset. */
  body.dvh21p2-returning:not(.dvh23b7-fi-focused) #my-waters:target{
    display:grid!important;
    width:100vw!important;
    max-width:none!important;
    margin:0 0 0 calc(50% - 50vw)!important;
    padding:20px var(--dvh-home-gutter) 22px!important;

    grid-template-columns:minmax(0,1fr)!important;
    grid-template-rows:auto auto auto auto!important;
    row-gap:0!important;
    column-gap:0!important;

    border:0!important;
    border-top:1px solid #e0ddd2!important;
    border-bottom:1px solid #e0ddd2!important;
    border-radius:0!important;
    background:var(--dvh-home-cream,#f7f4ec)!important;
    box-shadow:none!important;
    color:#0b392d!important;
  }

  /* Heading becomes a normal Home section header across the content line. */
  body.dvh21p2-returning:not(.dvh23b7-fi-focused) #my-waters:target .dvh23c4-waters-head{
    grid-column:1!important;
    grid-row:1!important;
    width:100%!important;
    margin:0!important;
    padding:0 0 13px!important;
    border:0!important;
  }

  body.dvh21p2-returning:not(.dvh23b7-fi-focused) #my-waters:target .dvh23c4-waters-head h3{
    margin:4px 0 5px!important;
    max-width:none!important;
    color:#0b392d!important;
    font-family:Georgia,serif!important;
    font-size:clamp(1.7rem,2.35vw,2.25rem)!important;
    line-height:1!important;
  }

  body.dvh21p2-returning:not(.dvh23b7-fi-focused) #my-waters:target .dvh23c4-waters-head p{
    max-width:820px!important;
    margin:0!important;
    color:#68756f!important;
    font-size:.72rem!important;
    line-height:1.45!important;
  }

  /* Selected water now owns the full available width. */
  body.dvh21p2-returning:not(.dvh23b7-fi-focused) #my-waters:target .dvh23c4-current-water{
    grid-column:1!important;
    grid-row:2!important;
    width:100%!important;
    min-height:72px!important;
    margin:0!important;
    padding:11px 14px!important;

    display:grid!important;
    grid-template-columns:minmax(0,1fr) auto!important;
    gap:18px!important;
    align-items:center!important;

    border:1px solid #ddd8cb!important;
    border-radius:7px 7px 0 0!important;
    background:rgba(255,255,255,.68)!important;
    box-shadow:none!important;
  }

  body.dvh21p2-returning:not(.dvh23b7-fi-focused) #my-waters:target .dvh23c4-current-water>div{
    min-width:0!important;
  }

  body.dvh21p2-returning:not(.dvh23b7-fi-focused) #my-waters:target .dvh23c4-current-water strong{
    color:#073f31!important;
    font-size:1.12rem!important;
  }

  body.dvh21p2-returning:not(.dvh23b7-fi-focused) #my-waters:target .dvh23c4-current-water nav{
    display:flex!important;
    align-items:center!important;
    justify-content:flex-end!important;
    gap:7px!important;
  }

  body.dvh21p2-returning:not(.dvh23b7-fi-focused) #my-waters:target .dvh23c4-current-water nav a{
    min-height:40px!important;
    padding:8px 13px!important;
    border:1px solid #d8d5ca!important;
    border-radius:4px!important;
    background:#fffdf8!important;
    color:#0b4938!important;
    font-size:.68rem!important;
    font-weight:900!important;
    text-decoration:none!important;
    text-shadow:none!important;
    box-shadow:none!important;
  }

  /* Explicit high-contrast primary action.
     This overrides the inherited white-on-light state from older phases. */
  body.dvh21p2-returning:not(.dvh23b7-fi-focused) #my-waters:target .dvh23c4-current-water nav a.is-primary{
    border-color:#e6a821!important;
    background:#e6a821!important;
    color:#073d2f!important;
    text-shadow:none!important;
    box-shadow:none!important;
  }

  body.dvh21p2-returning:not(.dvh23b7-fi-focused) #my-waters:target .dvh23c4-current-water nav a.is-primary:hover,
  body.dvh21p2-returning:not(.dvh23b7-fi-focused) #my-waters:target .dvh23c4-current-water nav a.is-primary:focus-visible{
    border-color:#d69a18!important;
    background:#efb32b!important;
    color:#073d2f!important;
  }

  /* Saved waters become a full-width contextual row. */
  body.dvh21p2-returning:not(.dvh23b7-fi-focused) #my-waters:target .dvh23c4-saved-preview,
  body.dvh21p2-returning:not(.dvh23b7-fi-focused) #my-waters:target .dvh23c4-no-waters{
    grid-column:1!important;
    grid-row:3!important;
    width:100%!important;
    margin:0!important;
    padding:11px 14px 13px!important;
    border-left:1px solid #ddd8cb!important;
    border-right:1px solid #ddd8cb!important;
    background:rgba(255,255,255,.46)!important;
  }

  body.dvh21p2-returning:not(.dvh23b7-fi-focused) #my-waters:target .dvh23c4-saved-preview .dvh23b5-water-chips{
    margin:7px 0 0!important;
    display:flex!important;
    flex-wrap:wrap!important;
    gap:6px!important;
  }

  body.dvh21p2-returning:not(.dvh23b7-fi-focused) #my-waters:target .dvh23c4-saved-preview .dvh23b5-water-chips span{
    padding:6px 9px!important;
    border:1px solid #d9d5c9!important;
    border-radius:4px!important;
    background:#fff!important;
    color:#24483e!important;
  }

  /* Compare becomes the full-width final decision row. */
  body.dvh21p2-returning:not(.dvh23b7-fi-focused) #my-waters:target .dvh23c4-compare{
    grid-column:1!important;
    grid-row:4!important;
    width:100%!important;
    min-height:66px!important;
    margin:0!important;
    padding:11px 14px!important;

    border:1px solid #ddd8cb!important;
    border-top:0!important;
    border-bottom:3px solid #e6a821!important;
    border-radius:0 0 7px 7px!important;
    background:#fff!important;
    color:#0b392d!important;
    box-shadow:none!important;
  }
}

/* Tablet / mobile: stay one-column and remove any inherited side-card feel. */
@media(max-width:900px){
  body.dvh21p2-returning:not(.dvh23b7-fi-focused) #my-waters:target{
    width:100%!important;
    margin:0!important;
    padding:16px var(--dvh-home-gutter,16px) 17px!important;
    display:grid!important;
    grid-template-columns:1fr!important;
    gap:0!important;
    border-radius:0!important;
  }

  body.dvh21p2-returning:not(.dvh23b7-fi-focused) #my-waters:target .dvh23c4-waters-head{
    padding:0 0 11px!important;
  }

  body.dvh21p2-returning:not(.dvh23b7-fi-focused) #my-waters:target .dvh23c4-current-water{
    display:block!important;
    padding:11px!important;
    border-radius:7px 7px 0 0!important;
  }

  body.dvh21p2-returning:not(.dvh23b7-fi-focused) #my-waters:target .dvh23c4-current-water nav{
    width:100%!important;
    margin-top:10px!important;
    display:grid!important;
    grid-template-columns:repeat(2,minmax(0,1fr))!important;
    gap:6px!important;
  }

  body.dvh21p2-returning:not(.dvh23b7-fi-focused) #my-waters:target .dvh23c4-current-water nav a{
    width:100%!important;
  }
}

@media(max-width:520px){
  body.dvh21p2-returning:not(.dvh23b7-fi-focused) #my-waters:target .dvh23c4-current-water nav{
    grid-template-columns:1fr!important;
  }
}
