/*
Theme Name: Ushijima Portfolio
*/
:root {
  --blue: #2563eb;
  --blue-hover: #1d4ed8;
  --blue-light: #eff6ff;
  --text: #0f172a;
  --text-muted: #64748b;
  --text-soft: #475569;
  --text-faint: #94a3b8;
  --border: #e2e8f0;
  --border-input: #cbd5e1;
  --bg-muted: #f1f5f9;
  --white: #fff;
  --max: 1120px;
  --font-sans: "Inter", ui-sans-serif, system-ui, sans-serif;
  --font-display: "DM Sans", ui-sans-serif, system-ui, sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-sans);
  background: var(--white);
  color: var(--text);
  -webkit-font-smoothing: antialiased;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: inherit;
}

h1,
h2,
h3 {
  font-family: var(--font-display);
}

.container {
  max-width: var(--max);
  margin: 0 auto;
  padding-left: 40px;
  padding-right: 40px;
}

.divider {
  border: 0;
  border-top: 1px solid var(--border);
  margin: 0;
}

.label {
  margin: 0 0 16px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--blue);
}

.section {
  padding-top: 100px;
  padding-bottom: 100px;
}

.section__title {
  margin: 0 32px;
  font-size: clamp(28px, 3vw, 38px);
  font-weight: 700;
  letter-spacing: -0.03em;
  color: var(--text);
}

/* Header */
.header {
  position: fixed;
  inset: 0 0 auto;
  z-index: 50;
  height: 64px;
  background: transparent;
  border-bottom: 1px solid transparent;
  transition: background 0.25s, border-color 0.25s, backdrop-filter 0.25s;
}

.header.is-scrolled {
  background: rgba(255, 255, 255, 0.96);
  border-bottom-color: var(--border);
  backdrop-filter: blur(10px);
}

.header__inner {
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 19px;
  text-decoration: none;
  color: var(--text);
}

.logo--sm {
  font-size: 17px;
}

.logo__dot {
  color: var(--blue);
}

.nav {
  display: flex;
  align-items: center;
  gap: 32px;
}

.nav__link {
  font-size: 14px;
  font-weight: 500;
  color: var(--text-muted);
  text-decoration: none;
  transition: color 0.15s;
}

.nav__link:hover {
  color: var(--text);
}

.nav-toggle {
  display: none;
  width: 40px;
  height: 40px;
  padding: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 6px;
}

.nav-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  background: var(--text);
  transition: transform 0.2s, opacity 0.2s;
}

.nav-toggle[aria-expanded="true"] span:first-child {
  transform: translateY(4px) rotate(45deg);
}

.nav-toggle[aria-expanded="true"] span:last-child {
  transform: translateY(-4px) rotate(-45deg);
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 600;
  text-decoration: none;
  border-radius: 6px;
  border: none;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s;
}

.btn--primary {
  color: var(--white);
  background: var(--blue);
  padding: 13px 30px;
}

.btn--primary:hover {
  background: var(--blue-hover);
}

.btn--sm {
  padding: 8px 20px;
  font-size: 14px;
}

.btn--outline {
  color: var(--blue);
  background: transparent;
  padding: 13px 28px;
  border: 1.5px solid var(--blue);
}

.btn--outline:hover {
  border-color: var(--blue);
}

/* Hero */
.hero {
  padding-top: 160px;
  padding-bottom: 120px;
}

.eyebrow {
  margin: 0 0 24px;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--blue);
}

.hero__title {
  margin: 0 0 32px;
  max-width: 720px;
  font-size: clamp(48px, 5.5vw, 72px);
  font-weight: 700;
  letter-spacing: -0.04em;
  line-height: 1.05;
  color: var(--text);
}

.sp-only {
  display: block;
}

.hero__lead {
  margin: 0 0 48px;
  max-width: 560px;
  font-size: 17px;
  line-height: 1.8;
  color: var(--text-muted);
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}

/* Service */
.service-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  margin-top: 56px;
}

.service-item {
  padding: 36px 40px;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.service-item:nth-child(-n + 2) {
  border-bottom: none;
}

.service-item__no {
  margin-bottom: 14px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--blue);
}

.service-item__title {
  margin: 0 0 12px;
  font-size: 18px;
  font-weight: 700;
  color: var(--text);
}

.service-item__desc {
  margin: 0;
  font-size: 14px;
  line-height: 1.8;
  color: var(--text-muted);
}

/* Works */
.works-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-top: 56px;
}
.works-grid > .wp-block-group__inner-container {
  display: contents;
}

.work-card {
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid var(--border);
  cursor: pointer;
  transition: box-shadow 0.2s;
}

.work-card:hover {
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.08);
}

.work-card__media {
  background: var(--bg-muted);
  overflow: hidden;
}

.work-card__media img {
  width: 100%;
  height: 200px;
  object-fit: cover;
  transition: transform 0.35s;
}

.work-card:hover .work-card__media img {
  transform: scale(1.04);
}

.work-card__body {
  padding: 10px 20px 10px;
}

.work-card__body p {
  margin: 0;
}

.work-card__category {
  margin-bottom: 6px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--blue);
}

.work-card__title {
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 500;
  color: var(--text);
}

/* About */
.about {
  display: grid;
  grid-template-columns: 340px 1fr;
  gap: 80px;
  margin-top: 48px;
}

.about > .wp-block-group__inner-container {
  display: contents;
}

.about__media {
  background: var(--bg-muted);
  border-radius: 8px;
  overflow: hidden;
}

.about__media img {
  width: 100%;
  height: 480px;
  object-fit: cover;
}

.about__content {
  padding-top: 8px;
}

.about__name {
  font-family: var(--font-display);
  margin: 0 0 6px;
  font-size: 32px;
  font-weight: 500;
  letter-spacing: -0.03em;
  color: var(--text);
}

.about__role {
  margin: 0 0 28px;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.06em;
  color: var(--blue);
}

.about__text {
  margin: 0 0 16px;
  font-size: 15px;
  line-height: 1.9;
  color: var(--text-soft);
}

.about__text--last {
  margin-bottom: 48px;
}

.skills {
  border-top: 1px solid var(--border);
  padding-top: 36px;
}

.skills__label {
  margin-bottom: 20px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-faint);
}

.skills__list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.skills__list li {
  font-size: 13px;
  font-weight: 500;
  color: #334155;
  background: var(--bg-muted);
  padding: 6px 16px;
  border-radius: 100px;
  border: 1px solid var(--border);
}

/* Contact */
.contact {
  max-width: 640px;
  margin: 0 auto;
  padding-left: 40px;
  padding-right: 40px;
}

.contact__lead {
  margin: 0 0 48px;
  font-size: 15px;
  line-height: 1.8;
  color: var(--text-muted);
}

.contact-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.contact-form__row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.field label {
  display: block;
  margin-bottom: 12px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-soft);
}

.field input,
.field textarea {
  width: 100%;
  border: 1px solid var(--border-input);
  border-radius: 6px;
  padding: 11px 14px;
  font-size: 14px;
  font-family: var(--font-sans);
  color: var(--text);
  background: var(--white);
  outline: none;
  transition: border-color 0.15s;
}

.wpcf7 input[type="text"],
.wpcf7 input[type="email"],
.wpcf7 textarea {
  width: 100%;
  border: 1px solid var(--border-input);
  border-radius: 6px;
  padding: 11px 14px;
  font-size: 14px;
  font-family: var(--font-sans);
  color: var(--text);
  background: var(--white);
}
.wpcf7 input[type="submit"] {
  background: var(--blue);
  color: var(--white);
  border: none;
  border-radius: 6px;
  padding: 12px 24px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
}

.field textarea {
  resize: vertical;
  min-height: 120px;
}

.field input:focus,
.field textarea:focus {
  border-color: var(--blue);
}

.contact__success {
  padding: 48px 0;
  text-align: center;
}

.contact__success-icon {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--blue-light);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 20px;
}

.contact__success-title {
  margin: 0 0 8px;
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 700;
  color: var(--text);
}

.contact__success-text {
  margin: 0;
  font-size: 14px;
  color: var(--text-muted);
}

/* Footer */
.footer {
  border-top: 1px solid var(--border);
}

.footer__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 28px;
  padding-bottom: 28px;
}

.footer__copy {
  font-size: 13px;
  color: var(--text-faint);
}

/* Responsive */
@media (max-width: 900px) {
  .works-grid {
    grid-template-columns: 1fr 1fr;
  }

  .about {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .about__media img {
    height: 360px;
  }
}

@media (max-width: 720px) {
  .container,
  .contact {
    padding-left: 20px;
    padding-right: 20px;
  }

  .nav-toggle {
    display: flex;
  }

  .nav {
    display: none;
    position: absolute;
    top: 64px;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 12px 20px 20px;
    background: rgba(255, 255, 255, 0.98);
    border-bottom: 1px solid var(--border);
  }

  .nav.is-open {
    display: flex;
  }

  .nav__link {
    padding: 14px 0;
    border-bottom: 1px solid var(--border);
  }

  .nav .btn {
    margin-top: 16px;
    align-self: flex-start;
  }

  .hero {
    padding-top: 120px;
    padding-bottom: 80px;
  }

  .hero__title {
    font-size: clamp(34px, 9vw, 44px);
  }
  
  .sp-only {
  display: block;
  }

  .section {
    padding-top: 72px;
    padding-bottom: 72px;
  }

  .service-grid {
    grid-template-columns: 1fr;
  }

  .service-item,
  .service-item:nth-child(odd) {
    border-right: none;
    padding: 28px 0;
  }

  .service-item:nth-child(-n + 2) {
    border-bottom: 1px solid var(--border);
  }

  .service-item:last-child {
    border-bottom: none;
  }

  .works-grid {
    grid-template-columns: 1fr;
  }

  .contact-form__row {
    grid-template-columns: 1fr;
  }

  .footer__inner {
    flex-direction: column;
    gap: 10px;
    align-items: flex-start;
  }
}

#works .section__title {
  margin-bottom: 32px;
}

.wp-block-button.btn--primary {
  background: transparent;
  padding: 0;
}

.wp-block-button.btn--outline {
  background: transparent;
  padding: 0;
}

.wp-block-button.btn--outline {
  background: transparent;
  padding: 0;
  border: none;
}

.wp-block-button.btn--outline .wp-block-button__link {
  color: var(--blue);
  background: white;
  border: 1.5px solid var(--blue);
}

.wp-block-button.btn--primary .wp-block-button__link {
  color: white;
  background: var(--blue);
  border: 1.5px solid var(--blue);
}

.wpcf7-form-control-wrap {
  display: block;
  margin-top: 8px;
}