/* ==========================================================================
   justintauber.com
   The page's visual design lives in inline styles carried over from the
   Claude Design export. This file holds only what an inline style cannot
   express: @font-face, pseudo-classes, media queries and responsive art.
   ========================================================================== */

/* --- Fonts -------------------------------------------------------------- */
/* Self-hosted so the page needs no third-party round-trip to render.
   Manrope is the variable original (300-800). Newsreader styles exactly one
   paragraph, so it is pinned to wght 300 / opsz 40 and subset to latin. */

@font-face {
  font-family: 'Manrope';
  font-style: normal;
  font-weight: 300 800;
  font-display: swap;
  src: url('/assets/fonts/manrope-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA,
    U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193,
    U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Manrope';
  font-style: normal;
  font-weight: 300 800;
  font-display: swap;
  src: url('/assets/fonts/manrope-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF,
    U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020,
    U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Newsreader';
  font-style: normal;
  font-weight: 300;
  font-display: swap;
  src: url('/assets/fonts/newsreader-latin.woff2') format('woff2');
}
@font-face {
  font-family: 'Newsreader';
  font-style: italic;
  font-weight: 300;
  font-display: swap;
  src: url('/assets/fonts/newsreader-italic-latin.woff2') format('woff2');
}

/* --- Base --------------------------------------------------------------- */

body { margin: 0; background: #FFFBF2; -webkit-font-smoothing: antialiased; }
a { color: #10262E; text-decoration: none; }
a:hover { color: #FF3B14; }
footer a, nav a { color: inherit; }
img { max-width: 100%; }

/* The design removes the native focus ring on form fields in favour of a
   border colour change. Keep a real ring for keyboard users. */
:focus-visible { outline: 3px solid #FFC93C; outline-offset: 2px; }

.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  margin: -1px; padding: 0; border: 0;
  clip: rect(0 0 0 0); clip-path: inset(50%);
  overflow: hidden; white-space: nowrap;
}

/* --- Responsive art ----------------------------------------------------- */
/* Two decorative backgrounds. image-set() serves AVIF then WebP, and the
   plain background-image above it is the fallback any older engine uses. */

.hero-portrait {
  background-image: url('/assets/img/jt-portrait.jpg');
  background-image: -webkit-image-set(
    url('/assets/img/jt-portrait.avif') type('image/avif'),
    url('/assets/img/jt-portrait.webp') type('image/webp'),
    url('/assets/img/jt-portrait.jpg') type('image/jpeg'));
  background-image: image-set(
    url('/assets/img/jt-portrait.avif') type('image/avif'),
    url('/assets/img/jt-portrait.webp') type('image/webp'),
    url('/assets/img/jt-portrait.jpg') type('image/jpeg'));
}

.ethos-backdrop {
  background-image: url('/assets/img/ethos-design-logo.jpg');
  background-image: -webkit-image-set(
    url('/assets/img/ethos-design-logo.avif') type('image/avif'),
    url('/assets/img/ethos-design-logo.webp') type('image/webp'),
    url('/assets/img/ethos-design-logo.jpg') type('image/jpeg'));
  background-image: image-set(
    url('/assets/img/ethos-design-logo.avif') type('image/avif'),
    url('/assets/img/ethos-design-logo.webp') type('image/webp'),
    url('/assets/img/ethos-design-logo.jpg') type('image/jpeg'));
}

/* --- Hover states ------------------------------------------------------- */
/* Carried over from the export's style-hover attributes, which only the
   Claude Design runtime understood. */

/* These base colours live here rather than inline because an inline
   declaration outranks every stylesheet rule — including :hover and :focus. */

.card-link { background-color: #FFFFFF; transition: background-color .14s ease; }
.card-link:hover { background-color: #FFF8EC; }

.btn-submit { background-color: #10262E; transition: background-color .14s ease; }
.btn-submit:hover:not([disabled]) { background-color: #FF3B14; }
.btn-submit[disabled] { opacity: .62; cursor: progress; }

/* --- Contact form ------------------------------------------------------- */

.field { background-color: #FFFFFF; border: 1px solid #1C8A8A; }
.field:focus { border-color: #FF3B14; }

/* appearance:none strips the native dropdown marker, so draw one back in. */
select.field {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='9' viewBox='0 0 14 9'%3E%3Cpath d='M1 1l6 6 6-6' stroke='%2310262E' stroke-width='2' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 16px center;
  padding-right: 44px;
}
select.field:invalid { color: #6B7B7B; }

.field[aria-invalid="true"] { border-color: #FF3B14; border-width: 2px; }

#form-status[data-state="error"] { color: #FFD28A; font-weight: 600; }
#form-status[data-state="sent"]  { color: #FFF6E9; font-weight: 600; }

/* --- Anchor navigation -------------------------------------------------- */
/* The nav is position:sticky, so anchored sections need to clear it. */

html { scroll-behavior: smooth; }
#top, #point-of-view, #work-with-me, #experience, #ethos-design, #contact {
  scroll-margin-top: 84px;
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .card-link, .btn-submit { transition: none; }
}

/* --- Print -------------------------------------------------------------- */
@media print {
  nav, #contact form { display: none; }
  body { background: #fff; }
}
