/* Deductifi block theme — member + marketing polish */
html {
  height: 100%;
}

body {
  min-height: 100%;
  margin: 0;
  font-family: "IBM Plex Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
  font-weight: 400;
  color: #35415b;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

.wp-site-blocks {
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  width: 100%;
}

.wp-site-blocks > main {
  flex: 1 0 auto;
}

.wp-site-blocks > footer,
.deductifi-public-footer-wrap,
.deductifi-member-footer-wrap {
  flex-shrink: 0;
  margin-top: auto;
  width: 100%;
}

.site-header {
  border-bottom: 1px solid var(--wp--preset--color--deductifi-border, #e3e7f0);
  background: #fff;
}

.deductifi-callout {
  max-width: 780px;
  margin: 0 auto;
  padding: 12px 14px;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  background: #f8fafc;
}

.wp-site-blocks main {
  padding: 1.5rem 1.25rem 2.5rem;
  max-width: 1120px;
  margin-left: auto;
  margin-right: auto;
  width: 100%;
  box-sizing: border-box;
}

/* Marketing pages: full-bleed sections inside block theme */
.wp-site-blocks main:has(.deductifi-marketing) {
  max-width: none;
  padding-top: 0;
  padding-bottom: 0;
  margin-left: 0;
  margin-right: 0;
}

/* Member dashboard bleed was for Impreza narrow column; block theme uses normal flow */
.deductifi-member-dash-bleed,
.deductifi-assets-dash-bleed {
  width: 100% !important;
  max-width: 100% !important;
  margin-left: 0 !important;
  margin-right: 0 !important;
  padding-left: 0 !important;
  padding-right: 0 !important;
}

/* Public marketing header */
.deductifi-public-header-wrap {
  border-bottom: 1px solid #e3e7f0;
  background: #fff;
}

.deductifi-public-header {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0.65rem 1.25rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.deductifi-public-header__brand {
  display: inline-flex;
  line-height: 0;
}

.deductifi-public-header__brand img {
  height: 48px;
  width: auto;
  max-width: 180px;
}

.deductifi-public-menu {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem 1.25rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.deductifi-public-menu a {
  color: #35415b;
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: 500;
}

.deductifi-public-menu a:hover,
.deductifi-public-menu .current-menu-item > a,
.deductifi-public-menu .current_page_item > a {
  color: #646cfd;
}

.deductifi-public-menu__cta a {
  display: inline-block;
  padding: 0.4rem 0.85rem;
  border: 2px solid #646cfd;
  border-radius: 6px;
  color: #646cfd !important;
}

.deductifi-public-menu__cta a:hover {
  background: #646cfd;
  color: #fff !important;
}

.df-public-builder-page {
  max-width: 100%;
  overflow-x: hidden;
}

.deductifi-mytax-report,
.deductifi-expenses-report,
#deductifi-report-body {
  max-width: 1120px;
  margin-left: auto;
  margin-right: auto;
}

footer.wp-block-template-part {
  margin-top: auto;
  padding: 0 !important;
}

footer.wp-block-template-part,
.deductifi-public-footer-wrap {
  background: var(--wp--preset--color--deductifi-footer, #0f131f);
  color: #8d9096;
}

footer.wp-block-template-part a,
.deductifi-public-footer-wrap a {
  color: var(--wp--preset--color--deductifi-primary, #646cfd);
}

.deductifi-public-footer {
  max-width: 1120px;
  margin: 0 auto;
  padding: 1.5rem 1.25rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.deductifi-public-footer__copy {
  margin: 0;
  font-size: 0.875rem;
}

.deductifi-footer-menu {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.25rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.deductifi-footer-menu a {
  font-size: 0.875rem;
  text-decoration: none;
}

.wp-block-details {
  border: 1px solid #e3e7f0;
  border-radius: 8px;
  padding: 0.75rem 1rem;
  margin-bottom: 0.75rem;
  background: #fff;
}

.wp-block-details summary {
  font-weight: 600;
  color: #0f131f;
  cursor: pointer;
}

/* Logged-in member header (Impreza app-header + dashboard action menus) */
.deductifi-member-header-wrap {
  background: #fff;
  border-bottom: none;
}

.deductifi-member-header__bar {
  width: 100%;
  border-bottom: 1px solid #e3e7f0;
}

.deductifi-member-header__bar--tabs {
  background: #f8fafc;
}

.deductifi-member-header__inner {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0.55rem 1.25rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.deductifi-member-header__brand {
  display: inline-flex;
  line-height: 0;
  text-decoration: none;
  flex-shrink: 0;
}

.deductifi-member-header__brand img {
  height: 42px;
  width: auto;
  max-width: 160px;
}

.deductifi-member-menu {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem 1rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.deductifi-member-menu a {
  color: #35415b;
  text-decoration: none;
  font-size: 0.9375rem;
  font-weight: 500;
  padding: 0.2rem 0;
  white-space: nowrap;
  letter-spacing: 0;
}

.deductifi-member-menu a:hover,
.deductifi-member-menu .current-menu-item > a,
.deductifi-member-menu .current_page_item > a {
  color: #646cfd;
}

.deductifi-member-menu--account a {
  font-size: 0.88rem;
  font-weight: 500;
}

.deductifi-member-menu--primary {
  gap: 0.25rem 1.5rem;
}

.deductifi-member-menu--primary a {
  display: inline-block;
  padding: 0.45rem 0 0.55rem;
  border-bottom: 2px solid transparent;
}

.deductifi-member-menu--primary .current-menu-item > a,
.deductifi-member-menu--primary .current_page_item > a {
  color: #0f131f;
  border-bottom-color: #646cfd;
}

/* Member pages: compact footer with support links */
.deductifi-member-footer-wrap {
  background: #0f131f;
  color: #8d9096;
  margin-top: 2rem;
}

.deductifi-member-footer {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0.85rem 1.25rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem 1.25rem;
}

.deductifi-member-footer__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem 1.25rem;
  min-width: 0;
  flex: 1 1 280px;
}

.deductifi-member-footer p {
  margin: 0;
  font-size: 0.8rem;
}

.deductifi-member-footer__list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 1rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.deductifi-member-footer__list a {
  color: #c5c9fe;
  text-decoration: none;
  font-size: 0.8rem;
  font-weight: 500;
}

.deductifi-member-footer__list a:hover {
  color: #fff;
}

.deductifi-public-footer__meta {
  max-width: 520px;
}

.deductifi-public-footer__note {
  margin: 0.35rem 0 0;
  font-size: 0.75rem;
  line-height: 1.4;
  color: #8d9096;
}

.deductifi-tpb-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  flex: 0 0 auto;
  line-height: 1.15;
  color: #fff;
}

.deductifi-tpb-badge__mark {
  display: block;
  width: 40px;
  height: auto;
  flex: 0 0 auto;
}

.deductifi-tpb-badge__meta {
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
  min-width: 0;
}

.deductifi-tpb-badge__label {
  font-size: 0.72rem;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.78);
  letter-spacing: 0.01em;
}

.deductifi-tpb-badge__number {
  font-size: 0.9rem;
  font-weight: 600;
  color: #fff;
  letter-spacing: 0.02em;
  font-variant-numeric: tabular-nums;
}

/* Contact page */
.deductifi-contact-page {
  max-width: 720px;
  margin: 0 auto;
  padding: 2rem 1.25rem 3rem;
}

.deductifi-contact-page h1 {
  margin: 0 0 0.5rem;
  color: #0f131f;
  font-size: clamp(1.75rem, 2.5vw, 2.15rem);
  font-weight: 700;
  letter-spacing: -0.02em;
}

.deductifi-contact-page__lede {
  margin: 0 0 1.5rem;
  color: #4b5568;
  font-size: 1.05rem;
  line-height: 1.55;
  max-width: 42rem;
}

.deductifi-contact-page__card {
  background: #fff;
  border: 1px solid #e5e9f2;
  border-radius: 16px;
  padding: 1.35rem 1.35rem 1.5rem;
  box-shadow: 0 10px 30px rgba(15, 19, 31, 0.04);
}

.deductifi-contact-page .frm_forms .frm_form_field {
  margin-bottom: 1rem;
}

.deductifi-contact-page .frm_primary_label {
  display: inline-flex;
  align-items: baseline;
  gap: 0.25rem;
  margin: 0 0 0.4rem;
  color: #1f2937;
  font-size: 0.92rem;
  font-weight: 600;
  line-height: 1.3;
}

.deductifi-contact-page .frm_required,
.deductifi-contact-page .frm_required_star {
  color: #c2410c;
  font-weight: 700;
}

.deductifi-contact-page .frm_form_field input[type="text"],
.deductifi-contact-page .frm_form_field input[type="email"],
.deductifi-contact-page .frm_form_field textarea,
.deductifi-contact-page .with_frm_style input[type="text"],
.deductifi-contact-page .with_frm_style input[type="email"],
.deductifi-contact-page .with_frm_style textarea {
  width: 100%;
  box-sizing: border-box;
  border: 1px solid #d5dbe8;
  border-radius: 10px;
  background: #fff;
  color: #0f131f;
  padding: 0.7rem 0.85rem;
  font-size: 1rem;
  line-height: 1.4;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.deductifi-contact-page .frm_form_field textarea,
.deductifi-contact-page .with_frm_style textarea {
  min-height: 9rem;
  resize: vertical;
}

.deductifi-contact-page .frm_form_field input:focus,
.deductifi-contact-page .frm_form_field textarea:focus,
.deductifi-contact-page .with_frm_style input:focus,
.deductifi-contact-page .with_frm_style textarea:focus {
  outline: none;
  border-color: #5b8def;
  box-shadow: 0 0 0 3px rgba(91, 141, 239, 0.18);
  background: #fff;
}

.deductifi-contact-page .frm_submit {
  margin-top: 0.35rem;
}

.deductifi-contact-page .frm_submit .frm_button_submit,
.deductifi-contact-page .frm_button_submit,
.deductifi-contact-page input[type="submit"] {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.6rem;
  padding: 0.65rem 1.35rem;
  border: 0;
  border-radius: 10px;
  background: #1ea56a;
  color: #fff;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: background-color 0.15s ease, transform 0.15s ease;
}

.deductifi-contact-page .frm_submit .frm_button_submit:hover,
.deductifi-contact-page .frm_button_submit:hover,
.deductifi-contact-page input[type="submit"]:hover {
  background: #178a58;
}

.deductifi-contact-page .frm_error,
.deductifi-contact-page .frm_error_style {
  color: #b42318;
  font-size: 0.85rem;
}

@media (max-width: 782px) {
  .deductifi-member-header__inner {
    flex-wrap: wrap;
  }

  .deductifi-member-header__account {
    width: 100%;
  }

  .deductifi-member-menu--account {
    justify-content: flex-start;
  }

  .deductifi-contact-page__card {
    padding: 1.1rem;
    border-radius: 14px;
  }
}
