/* MJK Electric — contact page (templates/website/contact.html). Loaded after css/home_v2.css (tokens, nav,
   buttons, section heads, the split "live" section, spec strip, footer) and css/services.css (photo header,
   city links). See docs/home_v2.md. */

/* ----------------------------------------------------------------- header */
.contact .shero { min-height: min(76vh, 740px); }
/* the truck and the lit door sit in the right half of the photo */
.contact .shero__media img { object-position: 76% 50%; }
/* the copper half of the title on its own line, so the headline stays over the dark side of the photo */
.contact .shero__title em { display: block; }
.contact .shero__lede { max-width: 33em; }
.contact .shero .hero__cta { margin-top: clamp(24px, 3vw, 36px); }
/* four rows in this header (eyebrow, title, lede, buttons); services.css times the first three */
.js .contact .shero__in > :nth-child(4) { animation-delay: .42s; }
.specs a.specs__v { transition: color .2s; }
.specs a.specs__v:hover { color: var(--copper-hi); }

/* ------------------------------------------------- 01 start a conversation */
.sec--message { padding: clamp(64px, 8vw, 120px) 0 clamp(84px, 10vw, 150px); scroll-margin-top: 56px; background:
    radial-gradient(900px 560px at 14% 34%, rgba(194, 124, 46, .11), transparent 62%), var(--bg); }
.message { display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(300px, 1fr); gap: clamp(32px, 5vw, 84px); align-items: start; }
.message__main .display { max-width: 11em; margin-bottom: clamp(26px, 3.2vw, 42px); font-size: clamp(2.4rem, 4.5vw, 4.1rem); }

/* what the server says back after Send (Django messages) */
.notes { display: grid; gap: 10px; margin-bottom: 22px; }
.note { padding: 14px 18px; border: 1px solid var(--line-2); border-left-width: 3px; border-radius: 3px; background: rgba(255, 255, 255, .04); color: var(--text); font-size: 1rem; line-height: 1.5; }
.note--success { border-color: rgba(120, 205, 150, .55); background: rgba(58, 150, 96, .14); color: #d3f2dd; }
.note--error { border-color: rgba(255, 128, 106, .6); background: rgba(196, 70, 48, .14); color: #ffd6cd; }
.note ul { margin: 0; padding: 0; list-style: none; }

/* the form, as a service request ticket */
.ticket { --pad: clamp(20px, 2.8vw, 38px); position: relative; overflow: hidden; border: 1px solid var(--line-2); border-radius: 6px;
    background: linear-gradient(180deg, rgba(24, 29, 34, .92), rgba(15, 18, 22, .96));
    box-shadow: 0 50px 100px -40px rgba(0, 0, 0, .95), 0 0 0 1px rgba(0, 0, 0, .5), 0 0 90px -30px rgba(226, 150, 74, .28); }
.ticket::before { content: ''; position: absolute; left: 0; right: 0; top: 0; height: 3px; background: linear-gradient(90deg, #e9a55c, #a8651f 60%, rgba(168, 101, 31, 0)); }
.ticket__head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 14px 32px; padding: calc(var(--pad) + 3px) var(--pad) clamp(18px, 2.2vw, 26px); border-bottom: 1px solid var(--line); }
.ticket__k { color: var(--copper-hi); }
.ticket__title { margin: 8px 0 0; font-family: var(--display); font-weight: 600; font-size: clamp(1.9rem, 2.6vw, 2.5rem); line-height: 1; letter-spacing: .01em; text-transform: uppercase; color: #fff; }
.ticket__note { max-width: 23em; font-size: .9rem; line-height: 1.5; color: var(--muted); }

.cform { display: grid; gap: clamp(18px, 2vw, 24px); padding: clamp(20px, 2.4vw, 30px) var(--pad) var(--pad); }
.cform__row { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(14px, 1.6vw, 20px); }
.cfield { display: grid; gap: 8px; min-width: 0; align-content: start; }
.cfield label { font-family: var(--mono); font-size: .68rem; font-weight: 500; letter-spacing: .16em; text-transform: uppercase; color: var(--muted); }
.req { color: var(--copper-hi); font-weight: 700; }
.cfield input, .cfield textarea { display: block; width: 100%; margin: 0; border: 1px solid var(--line-2); border-radius: 3px; background: rgba(9, 11, 13, .62); color: #fff; font: 400 1rem/1.4 var(--body); -webkit-appearance: none; appearance: none; transition: border-color .2s, box-shadow .2s, background .2s; }
.cfield input { height: 54px; padding: 0 16px; }
.cfield textarea { min-height: 184px; padding: 14px 16px; line-height: 1.55; resize: vertical; }
.cfield input::placeholder, .cfield textarea::placeholder { color: #70767d; }
.cfield input:hover, .cfield textarea:hover { border-color: rgba(255, 255, 255, .3); }
.cfield input:focus, .cfield textarea:focus { outline: 0; border-color: rgba(234, 168, 98, .8); background: rgba(9, 11, 13, .82); box-shadow: 0 0 0 4px rgba(194, 124, 46, .16); }
/* a browser's saved-details fill would paint the field white */
.cfield input:-webkit-autofill { -webkit-text-fill-color: #fff; box-shadow: 0 0 0 100px #101418 inset; caret-color: #fff; }
.cfield.has-error input, .cfield.has-error textarea { border-color: rgba(255, 128, 106, .7); }
.cfield .errorlist { margin: 0; padding: 0; list-style: none; font-size: .88rem; line-height: 1.4; color: #ffb3a3; }
.cform__foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px 24px; margin-top: 4px; }
.cform__foot p { font-size: .88rem; color: var(--dim); }

/* contact details beside the form */
.reach { position: sticky; top: 92px; padding-left: clamp(22px, 3vw, 44px); border-left: 1px solid var(--line); }
.reach__title { font-family: var(--display); font-weight: 600; font-size: clamp(1.9rem, 2.6vw, 2.5rem); line-height: 1; letter-spacing: .01em; text-transform: uppercase; color: #fff; }
.reach__lede { margin-top: 16px; font-size: .98rem; color: var(--muted); }
.reach__phone { display: grid; gap: 6px; margin-top: 26px; padding: 20px 22px 22px; border: 1px solid var(--line-2); border-radius: 4px; background: var(--panel); transition: border-color .25s, background .25s, transform .3s var(--ease); }
.reach__phone:hover { border-color: rgba(234, 168, 98, .7); background: var(--panel-2); transform: translateY(-2px); }
.reach__phone > .mono { color: var(--copper-hi); font-size: .64rem; letter-spacing: .18em; }
.reach__num { font-family: var(--display); font-weight: 600; font-size: clamp(2.5rem, 3.5vw, 3.3rem); line-height: 1; letter-spacing: .01em; color: #fff; white-space: nowrap; }
.reach__tag { display: inline-flex; align-items: center; gap: 10px; margin-top: 6px; font-family: var(--mono); font-size: .68rem; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }
.reach__list { margin: 26px 0 0; padding: 0; border-top: 1px solid var(--line); }
.reach__list > div { display: grid; gap: 6px; padding: 16px 0 18px; border-bottom: 1px solid var(--line); }
.reach__list dt { font-family: var(--mono); font-size: .64rem; font-weight: 500; letter-spacing: .18em; text-transform: uppercase; color: var(--copper-hi); }
.reach__list dd { margin: 0; font-size: 1rem; line-height: 1.55; color: #dcd9d4; }
.reach__alt { margin-top: 22px; font-size: .96rem; color: var(--muted); }

/* --------------------------------------------------------- 02 business hours */
.sec--hours { scroll-margin-top: 64px; }
/* the electrician stands in the right fifth of the photo: keep the fade into the copy off him */
.sec--hours .live__media img { object-position: 80% 50%; }
.sec--hours .live__media::after { background: linear-gradient(180deg, rgba(9, 11, 13, 0) 50%, rgba(9, 11, 13, .88) 100%), linear-gradient(90deg, rgba(13, 16, 19, 0) 90%, var(--bg-2) 100%); }
.sec--hours .display { font-size: clamp(2.5rem, 4.6vw, 4.2rem); }

/* the week as a time chart, like a timer schedule: a bar for office hours, a dashed line for the emergency line */
.week { --day: 46px; --hrs: 112px; margin: clamp(28px, 3.2vw, 40px) 0 34px; }
.week__axis { position: relative; height: 18px; margin: 0 var(--hrs) 6px var(--day); font-family: var(--mono); font-size: .58rem; letter-spacing: .1em; text-transform: uppercase; color: var(--dim); }
.week__axis span { position: absolute; top: 0; white-space: nowrap; transform: translateX(-50%); }
.week__axis span:nth-child(1) { left: 0; transform: none; }
.week__axis span:nth-child(2) { left: 25%; }
.week__axis span:nth-child(3) { left: 50%; }
.week__axis span:nth-child(4) { left: 75%; }
.week__axis span:nth-child(5) { left: 100%; transform: translateX(-100%); }
.week__rows { border-bottom: 1px solid var(--line); }
.week__row { display: grid; grid-template-columns: var(--day) minmax(0, 1fr) var(--hrs); align-items: center; height: 36px; border-top: 1px solid var(--line); }
.week__day { font-family: var(--mono); font-size: .72rem; font-weight: 500; letter-spacing: .12em; text-transform: uppercase; color: #dcd9d4; transition: color .3s; }
.week__hrs { font-family: var(--mono); font-size: .68rem; letter-spacing: .04em; text-align: right; white-space: nowrap; color: #dcd9d4; }
.week__row--off .week__day, .week__row--off .week__hrs { color: var(--dim); }
.week__row.is-today .week__day { color: var(--copper-hi); }
.week__track { position: relative; align-self: stretch; background:
    linear-gradient(var(--line-2), var(--line-2)) 0 0 / 1px 100% no-repeat,
    linear-gradient(var(--line), var(--line)) 25% 0 / 1px 100% no-repeat,
    linear-gradient(var(--line), var(--line)) 50% 0 / 1px 100% no-repeat,
    linear-gradient(var(--line), var(--line)) 75% 0 / 1px 100% no-repeat,
    linear-gradient(var(--line-2), var(--line-2)) 100% 0 / 1px 100% no-repeat; }
/* emergency service: all 24 hours of every row */
.week__track::before { content: ''; position: absolute; left: 0; right: 0; top: 50%; height: 2px; margin-top: -1px; background: repeating-linear-gradient(90deg, #c98a45 0 8px, transparent 8px 13px); }
/* office hours: 7:00 to 17:00 of 24 */
.week__office { position: absolute; left: 29.1667%; width: 41.6667%; top: 50%; height: 14px; margin-top: -7px; border-radius: 1px; background: linear-gradient(180deg, #e9a55c, #a8651f); box-shadow: 0 0 18px rgba(226, 150, 74, .3); transform-origin: left; }
.js .week.reveal .week__office { transform: scaleX(0); transition: transform 1s var(--ease) .25s; }
.js .week.reveal.is-in .week__office { transform: none; }
/* the time now in Phoenix, placed by js/contact.js */
.week__nowmark { position: absolute; z-index: 1; top: -1px; bottom: -1px; width: 2px; margin-left: -1px; background: #fff; box-shadow: 0 0 0 3px rgba(255, 255, 255, .13), 0 0 16px 2px rgba(255, 255, 255, .55); }
.week__key { display: grid; gap: 10px; margin-top: 18px; }
.week__key li { display: flex; align-items: center; gap: 14px; font-size: .95rem; line-height: 1.4; color: var(--muted); }
.week__key li[hidden] { display: none; }
.week__key b { margin-right: 6px; font-weight: 600; color: #fff; }
.week__swatch { flex: none; position: relative; width: 28px; height: 14px; }
.week__swatch::before { content: ''; position: absolute; left: 0; right: 0; top: 50%; }
.week__swatch--office::before { height: 10px; margin-top: -5px; border-radius: 1px; background: linear-gradient(180deg, #e9a55c, #a8651f); }
.week__swatch--line::before { height: 2px; margin-top: -1px; background: repeating-linear-gradient(90deg, #c98a45 0 8px, transparent 8px 13px); }
.week__swatch--now::before { left: 50%; right: auto; top: 0; width: 2px; height: 14px; margin-left: -1px; background: #fff; box-shadow: 0 0 10px 1px rgba(255, 255, 255, .5); }
.hours__cta { display: flex; flex-wrap: wrap; gap: 14px; }

/* ---------------------------------------------------------- service areas */
.contact .sec--areas { border-top: 1px solid var(--line); }

/* ------------------------------------------------------------- responsive */
/* the chart shares the row with the photo here: room for three hour labels, not five */
@media (min-width: 901px) and (max-width: 1280px) {
    .week__axis span:nth-child(even) { display: none; }
}
@media (max-width: 1000px) {
    .message { grid-template-columns: minmax(0, 1fr); }
    .reach { position: static; padding: clamp(32px, 5vw, 44px) 0 0; border-left: 0; border-top: 1px solid var(--line); }
    .reach__phone { max-width: 440px; }
}
@media (max-width: 900px) {
    .contact .shero { min-height: 0; }
    /* the lit doorway sits behind the text at this width: a heavier shade keeps it readable */
    .contact .shero__shade { background:
        linear-gradient(90deg, rgba(9, 11, 13, .93) 0%, rgba(9, 11, 13, .76) 60%, rgba(9, 11, 13, .58) 100%),
        linear-gradient(180deg, rgba(9, 11, 13, .7) 0%, rgba(9, 11, 13, 0) 24%, rgba(9, 11, 13, .2) 58%, rgba(9, 11, 13, .9) 100%); }
    .sec--hours .live__media::after { background: linear-gradient(180deg, rgba(9, 11, 13, 0) 35%, rgba(13, 16, 19, .95) 100%); }
}
@media (max-width: 599px) {
    .contact .shero .hero__cta { gap: 12px; }
    .cform__row { grid-template-columns: minmax(0, 1fr); }
    .ticket__note { max-width: none; }
    .cform__foot .btn { width: 100%; }
    .reach__phone { max-width: none; }
    .week { --day: 40px; --hrs: 98px; }
    .week__axis { font-size: .56rem; letter-spacing: .06em; }
    .week__axis span:nth-child(even) { display: none; }
    .week__hrs { font-size: .64rem; letter-spacing: 0; }
    .week__key li { align-items: flex-start; }
    .week__swatch { margin-top: 4px; }
    .week__key b { display: block; margin-right: 0; }
    .hours__cta .btn { flex: 1 1 100%; }
}
@media (prefers-reduced-motion: reduce) {
    .js .week.reveal .week__office { transform: none; }
}
