/*
 * Windows 11 inspired visual refresh.
 * This file intentionally overrides the legacy theme styles without changing templates.
 */

:root {
  --win11-bg: #f4f8ff;
  --win11-bg-soft: #edf4ff;
  --win11-text: #0f172a;
  --win11-subtle: #475569;
  --win11-accent: #0a64f9;
  --win11-surface: rgba(255, 255, 255, 0.78);
  --win11-border: rgba(15, 23, 42, 0.12);
  --win11-shadow: 0 20px 50px -30px rgba(15, 23, 42, 0.65);
  --win11-radius: 18px;
  --katotech-tile-height: 192px;
  --katotech-slider-height: 396px;
  --katotech-tile-art-max-height: 112px;
}

body {
  background:
    radial-gradient(1200px circle at 8% -10%, rgba(10, 100, 249, 0.2), transparent 55%),
    radial-gradient(900px circle at 100% 10%, rgba(56, 189, 248, 0.22), transparent 60%),
    linear-gradient(180deg, var(--win11-bg) 0%, var(--win11-bg-soft) 100%);
  color: var(--win11-text);
  font-family: "Segoe UI Variable", "Segoe UI", "Noto Sans JP", "PingFang SC", "Microsoft YaHei", sans-serif;
}

p,
li,
h1,
h2,
h3,
h4,
h5,
td,
label,
.topsub-cont,
.pagecont p,
.footmenu ul li a {
  color: var(--win11-text);
}

header {
  position: sticky;
  top: 0;
  z-index: 999;
  border-top: 0;
  border-bottom: 1px solid var(--win11-border);
  background: var(--win11-surface);
  backdrop-filter: blur(16px) saturate(1.1);
  box-shadow: 0 10px 30px -24px rgba(15, 23, 42, 0.6);
}

#gm {
  margin-bottom: 1rem;
  padding: 0.55rem 0 0.9rem;
}

.header-logo {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  flex-wrap: wrap;
  position: relative;
}

.header-logo img {
  padding-top: 0;
}

.header-logo > a:first-child {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.88rem 1.22rem;
  border-radius: 0;
  background: #010080;
  box-shadow: none;
  line-height: 0;
}

.header-logo > a:first-child img {
  display: block;
  width: clamp(160px, 14.5vw, 236px);
  height: auto;
  filter: none;
}

#right-menu {
  position: static;
  margin-left: 0.75rem;
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 46px;
  height: 46px;
  border-radius: 14px;
  border: 1px solid var(--win11-border);
  background: rgba(255, 255, 255, 0.95);
  box-shadow: 0 8px 16px -12px rgba(15, 23, 42, 0.8);
  color: #0f172a !important;
  text-decoration: none;
}

.menu-icon {
  font-size: 1.45rem;
  line-height: 1;
  color: #0f172a !important;
}

.lang ul {
  display: flex;
  gap: 0.45rem;
  margin: 0;
  align-items: center;
}

.lang ul li {
  list-style: none;
  margin: 0;
  padding: 0.35rem 0.8rem;
  border-radius: 999px;
  border: 1px solid var(--win11-border);
  background: rgba(255, 255, 255, 0.88);
  font-size: 0.78rem;
  letter-spacing: 0.02em;
}

.lang ul a li {
  color: var(--win11-text);
}

.lang {
  position: static;
  right: auto;
  top: auto;
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 0.45rem;
}

.menubtn {
  align-self: center;
}

#gm > #menu-cont {
  display: none !important;
}

.sq-box,
.top-tile,
.sec-tile {
  overflow: visible;
}

.sq-box {
  padding-top: 1.45rem;
}

.top-tile {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  align-items: flex-start;
}

.top-tile .slidermainbox,
.top-tile .slidersidebox {
  width: calc(50% - 0.5rem);
}

.sec-tile .slidersidebox {
  width: 100%;
}

.slider-pro,
.sp-slides {
  border-radius: var(--win11-radius);
  overflow: hidden;
  box-shadow: var(--win11-shadow);
  background: rgba(255, 255, 255, 0.68);
}

#my-slider .sp-slide {
  position: absolute;
  inset: 0;
  display: block !important;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.45s ease;
}

#my-slider,
#my-slider .sp-slides,
#my-slider .sp-slide {
  height: var(--katotech-slider-height) !important;
}

#my-slider .sp-image {
  display: block !important;
  width: 100% !important;
  height: var(--katotech-slider-height) !important;
  object-fit: cover;
  object-position: center;
}

#my-slider .sp-slides {
  position: relative;
}

#my-slider .sp-slide:first-child {
  opacity: 1;
}

#my-slider.katotech-slider-ready .sp-slide {
  opacity: 0;
}

#my-slider.katotech-slider-ready .sp-slide.is-active {
  opacity: 1;
  pointer-events: auto;
}

.box-first,
.box-second {
  display: flex;
  gap: 0.8rem;
}

.sub-margin {
  width: calc(50% - 0.4rem);
}

.bgc01,
.bgc02,
.bgc03,
.bgc04,
.bgc05,
.bgc06 {
  border-radius: var(--win11-radius);
  border: 1px solid rgba(255, 255, 255, 0.3);
  box-shadow: var(--win11-shadow);
  overflow: hidden;
}

.bgc01 {
  background: linear-gradient(135deg, #3b82f6 0%, #0a64f9 100%);
}

.bgc02 {
  background: linear-gradient(135deg, #fb7185 0%, #f97316 100%);
}

.bgc03 {
  background: linear-gradient(135deg, #8b5cf6 0%, #6366f1 100%);
}

.bgc04 {
  background: linear-gradient(135deg, #22c55e 0%, #14b8a6 100%);
}

.bgc05 {
  background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
}

.bgc06 {
  background: linear-gradient(135deg, #e11d48 0%, #be123c 100%);
}

.bgc01 a,
.bgc02 a,
.bgc03 a,
.bgc04 a,
.bgc05 a,
.bgc06 a {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.8rem;
  height: var(--katotech-tile-height);
  padding: 0.9rem 0.9rem;
  text-decoration: none;
}

.katotech-tile-art {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: var(--katotech-tile-art-max-height);
  color: rgba(255, 255, 255, 0.98);
}

.katotech-tile-art--logo {
  width: auto;
  min-height: 0;
  max-width: 100%;
  margin: 0 auto;
  padding: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  line-height: 0;
}

.katotech-tile-icon {
  width: min(116px, 52%);
  height: min(116px, 52%);
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
  fill: none;
}

.katotech-tile-logo {
  display: block;
  width: min(100%, 128px) !important;
  max-width: 128px;
  max-height: 36px;
  object-fit: contain;
  filter: none;
}

.katotech-tile-label {
  display: block;
  max-width: 12ch;
  text-align: center;
  color: #ffffff;
  font-size: 1.02rem;
  font-weight: 700;
  line-height: 1.45;
  letter-spacing: 0.02em;
  text-shadow: 0 8px 20px rgba(15, 23, 42, 0.32);
}

.katotech-company-list {
  display: grid;
  gap: 1rem;
}

.katotech-company-card {
  padding: 1rem;
  border: 1px solid var(--win11-border);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.72);
}

.katotech-company-card h2 {
  margin-bottom: 0.8rem;
}

.katotech-company-card p {
  margin-bottom: 0.45rem;
}

.katotech-company-card dl {
  display: grid;
  grid-template-columns: 110px minmax(0, 1fr);
  gap: 0.45rem 0.9rem;
  margin: 0;
}

.katotech-company-card dt {
  font-weight: 700;
  color: var(--win11-subtle);
}

.katotech-company-card dd {
  margin: 0;
}

.katotech-page-stack {
  display: grid;
  gap: 1rem;
}

.katotech-page-grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.katotech-page-panel {
  padding: 1.2rem 1.25rem;
  border: 1px solid var(--win11-border);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.72);
}

.katotech-page-panel > :last-child {
  margin-bottom: 0;
}

.katotech-page-lead {
  font-size: 1.08rem;
  font-weight: 600;
  line-height: 1.9;
}

.katotech-check-list {
  margin: 0;
  padding-left: 1.2rem;
}

.katotech-check-list li + li {
  margin-top: 0.55rem;
}

.katotech-page-note {
  color: var(--win11-subtle);
  font-size: 0.94rem;
}

.katotech-page-figure {
  margin: 1rem 0 0;
}

.katotech-page-figure img {
  display: block;
  width: 100%;
  max-height: 380px;
  object-fit: cover;
  border-radius: 14px;
  box-shadow: 0 18px 40px rgba(15, 23, 42, 0.12);
}

.katotech-page-figure figcaption {
  margin-top: 0.65rem;
  color: var(--win11-subtle);
  font-size: 0.92rem;
  line-height: 1.7;
}

.katotech-info-grid {
  display: grid;
  grid-template-columns: 110px minmax(0, 1fr);
  gap: 0.45rem 0.9rem;
  margin: 0;
}

.katotech-info-grid dt {
  font-weight: 700;
  color: var(--win11-subtle);
}

.katotech-info-grid dd {
  margin: 0;
}

.katotech-price-table-wrap {
  overflow-x: auto;
}

.katotech-price-table {
  width: 100%;
  border-collapse: collapse;
  border-spacing: 0;
}

.katotech-price-table th,
.katotech-price-table td {
  padding: 0.82rem 0.9rem;
  border-bottom: 1px solid rgba(15, 23, 42, 0.1);
  text-align: left;
  vertical-align: top;
  color: var(--win11-text);
  background: transparent;
}

.katotech-price-table thead th {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--win11-subtle);
  background: rgba(10, 100, 249, 0.06);
}

.katotech-overview-panel a,
.katotech-company-card a,
.katotech-price-table a {
  color: var(--win11-accent);
}

.second-colum,
.info-colum .row,
.mail-form-blk,
.pagecont {
  border-radius: calc(var(--win11-radius) + 2px);
  border: 1px solid var(--win11-border);
  background: var(--win11-surface);
  backdrop-filter: blur(10px);
  box-shadow: var(--win11-shadow);
}

.pagecont {
  margin-top: 1.15rem;
}

.pagecont article {
  padding-top: 1rem;
}

.side-content {
  margin-top: 1rem;
}

.info-colum .row {
  padding-top: 1rem;
  padding-bottom: 0.4rem;
}

.second-colum {
  margin: 3rem 0 2rem;
}

.topsub-ttl,
h2,
h3,
h4,
.page-head,
.form-head,
.topinfo-ttl {
  border: 0;
  color: var(--win11-text);
}

.topsub-ttl,
h3 {
  border-bottom: 1px solid rgba(10, 100, 249, 0.2);
  font-weight: 700;
}

h2,
.page-head,
.form-head {
  background: linear-gradient(90deg, rgba(10, 100, 249, 0.11), rgba(56, 189, 248, 0.08));
  border-radius: 12px;
}

.mail-jump {
  border: 1px solid rgba(10, 100, 249, 0.25);
  background: linear-gradient(135deg, #173b8f 0%, #0f245d 100%);
  border-radius: 14px;
  box-shadow: 0 18px 36px -28px rgba(15, 23, 42, 0.85);
  color: #ffffff;
  text-align: center;
}

.mail-jump img {
  display: block;
  width: 100%;
  height: auto;
  filter: none;
}

.wpcf7 {
  color: var(--win11-text);
}

.wpcf7 label {
  color: var(--win11-text);
  font-weight: 600;
}

.wpcf7 input[type="text"],
.wpcf7 input[type="email"],
.wpcf7 input[type="tel"],
.wpcf7 input[type="url"],
.wpcf7 textarea {
  width: 100%;
  border: 1px solid rgba(15, 23, 42, 0.18);
  background: rgba(255, 255, 255, 0.96);
  color: var(--win11-text);
  box-shadow: inset 0 1px 2px rgba(15, 23, 42, 0.06);
}

.wpcf7 input:focus,
.wpcf7 textarea:focus {
  border-color: rgba(10, 100, 249, 0.65);
  outline: 3px solid rgba(10, 100, 249, 0.16);
}

.form-enter {
  display: flex;
  justify-content: center;
  margin: 2.5rem 0;
  text-align: center;
}

.form-enter .button,
.form-enter .button.alert {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: min(280px, 100%);
  min-height: 4rem;
  margin: 0;
  padding: 0;
  border-radius: 0;
  background: linear-gradient(135deg, #dc2626 0%, #b91c1c 100%);
  box-shadow: 0 18px 36px -28px rgba(127, 29, 29, 0.9);
  text-align: center;
}

.form-enter input,
.form-enter input.wpcf7-submit,
.wpcf7 input[type="submit"] {
  display: block;
  width: 100%;
  min-height: 4rem;
  margin: 0 !important;
  padding: 0 1.5rem !important;
  background: transparent !important;
  border: 0 !important;
  color: #ffffff !important;
  font-size: 1.35rem;
  font-weight: 700;
  line-height: 1;
  text-align: center;
  cursor: pointer;
}

.wpcf7 form .wpcf7-response-output {
  margin: 1.8rem auto 0;
  padding: 1rem 1.2rem;
  max-width: 760px;
  border-radius: 12px;
  color: var(--win11-text) !important;
  background: rgba(255, 255, 255, 0.95);
  border: 2px solid rgba(10, 100, 249, 0.35);
  text-align: center;
  font-weight: 700;
  line-height: 1.7;
}

.wpcf7 form.sent .wpcf7-response-output {
  border-color: rgba(22, 163, 74, 0.5);
  background: rgba(240, 253, 244, 0.95);
}

.wpcf7 form.invalid .wpcf7-response-output,
.wpcf7 form.unaccepted .wpcf7-response-output {
  border-color: rgba(249, 115, 22, 0.65);
  background: rgba(255, 247, 237, 0.96);
}

.wpcf7 form.failed .wpcf7-response-output,
.wpcf7 form.aborted .wpcf7-response-output {
  border-color: rgba(220, 38, 38, 0.65);
  background: rgba(254, 242, 242, 0.96);
}

.wpcf7-not-valid-tip {
  margin-top: 0.35rem;
  color: #b91c1c !important;
  font-weight: 700;
}

footer {
  margin-top: 2.5rem;
  border-top: 1px solid var(--win11-border);
  background: var(--win11-surface);
  backdrop-filter: blur(16px) saturate(1.05);
}

.foot-logobox,
.foot-menubox {
  padding-top: 2rem;
  padding-bottom: 2rem;
}

.copyright {
  background: transparent;
  border-top: 1px solid var(--win11-border);
}

.copyright p {
  color: var(--win11-subtle);
  letter-spacing: 0.02em;
}

.sidr,
#sidr-menu {
  background: rgba(248, 250, 255, 0.94);
  border-top: 0;
  border-left: 1px solid var(--win11-border);
  box-shadow: -16px 0 40px -26px rgba(15, 23, 42, 0.75);
  z-index: 10050;
  padding-top: 3.5rem !important;
}


.sidr ul {
  display: block;
  margin: 0;
  padding: 1rem 0;
}

.sidr ul li {
  margin: 0;
  padding: 0.5rem 1rem;
  border: 0;
  background: transparent;
  box-shadow: none;
  transition: none;
}

.sidr ul li:hover {
  transform: none;
  box-shadow: none;
}

.sidr ul li a {
  display: flex;
  align-items: center;
  min-height: 3.5rem;
  color: #f8fbff;
  padding: 0.35rem 0.65rem;
  border-radius: 16px;
  background: linear-gradient(135deg, #214eb7 0%, #15327b 100%);
  box-shadow: 0 14px 28px -22px rgba(15, 23, 42, 0.85);
}

.sidr ul li img {
  display: block;
  width: 100%;
  max-width: 244px;
  height: auto;
  margin: 0 auto;
  border-radius: 12px;
}

.sidr ul li a:hover,
.sidr ul li a:focus {
  background: linear-gradient(135deg, #3268e4 0%, #1f469e 100%);
}

@media (max-width: 1024px) {
  .sub-margin {
    width: 100%;
  }

  .katotech-page-grid {
    grid-template-columns: 1fr;
  }

  .top-tile .slidermainbox,
  .top-tile .slidersidebox,
  .sec-tile .slidersidebox {
    width: 100%;
  }

  .box-first,
  .box-second {
    flex-wrap: wrap;
  }

  .katotech-tile-icon {
    width: 82px;
    height: 82px;
  }
}

@media (max-width: 640px) {
  #gm {
    padding-top: 0.5rem;
    padding-bottom: 0.75rem;
  }

  .katotech-company-card dl,
  .katotech-info-grid {
    grid-template-columns: 1fr;
    gap: 0.25rem;
  }

  .katotech-page-panel {
    padding: 1rem;
  }

  .header-logo > a:first-child {
    padding: 0.56rem 0.82rem;
  }

  .lang ul {
    width: 100%;
    justify-content: flex-start;
  }

  .header-logo {
    gap: 0.55rem;
  }

  .lang {
    order: 3;
    width: 100%;
    margin-left: 0;
  }

  .menubtn {
    order: 2;
    margin-left: auto;
  }

  .topinfo-ttl {
    margin: 0.5rem 0 1rem;
    font-size: 1.2rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  * {
    animation: none !important;
    transition: none !important;
  }
}
