/* Page-specific styles for index-anti-design.php */

/* ─── HERO ─── */
.hero {
  border-top: none;
  padding: 64px 48px;
  background: var(--bg);
  border-bottom: var(--rule);
  text-align: center;
}

.hero h1 {
  font-size: clamp(32px, 4.5vw, 48px);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.08;
  margin-bottom: 24px;
}

.hero-sub {
  font-size: 16px;
  color: #555;
  line-height: 1.65;
  margin-bottom: 32px;
}

.hero-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

/* Anti-design Spreadsheet Widget */
.hero-sheet {
  background: #ffffff;
  border: 3px solid var(--text);
  box-shadow: 8px 8px 0px 0px var(--text);
  border-radius: 4px;
  font-family: monospace;
  overflow: hidden;
  position: relative;
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1), 8px 8px 0px 0px var(--text);
}

.sheet-title-bar {
  background: var(--yellow);
  border-bottom: 3px solid var(--text);
  padding: 8px 12px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-weight: 800;
  font-size: 12px;
  letter-spacing: 0.05em;
}

.sheet-close-btn {
  border: 1.5px solid var(--text);
  background: #ffffff;
  width: 16px;
  height: 16px;
  font-size: 9px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  cursor: not-allowed;
}

.sheet-grid {
  display: grid;
  grid-template-columns: 40px repeat(3, 1fr);
  background: var(--text);
  gap: 1.5px;
}

.sheet-header-cell, .sheet-index-cell {
  background: #e5e5e0;
  padding: 6px 8px;
  font-size: 11px;
  font-weight: bold;
  text-align: center;
  color: var(--text);
  user-select: none;
}

.sheet-cell {
  background: #ffffff;
  padding: 8px;
  font-size: 11px;
  min-height: 34px;
  color: var(--text);
  outline: none;
  border: none;
  transition: all 0.15s ease-in-out;
}

.sheet-cell[contenteditable="true"] {
  cursor: text;
}

.sheet-cell[contenteditable="true"]:focus {
  background: #fffbeb;
  box-shadow: inset 0 0 0 2px var(--yellow);
}

/* Formula / Alert cells */
.sheet-cell.formula {
  background: #f1f5f9;
  font-weight: bold;
}

.sheet-cell.alert {
  animation: cellFlash 1s infinite alternate;
}

@keyframes cellFlash {
  0% { background: #fef2f2; color: #991b1b; }
  100% { background: #fee2e2; color: #b91c1c; }
}

/* Error Overlay / Message on interaction */
.sheet-broken-overlay {
  position: absolute;
  bottom: 12px;
  left: 12px;
  right: 12px;
  background: #fee2e2;
  border: 2px solid #b91c1c;
  box-shadow: 4px 4px 0px 0px #b91c1c;
  padding: 12px;
  color: #991b1b;
  font-size: 11px;
  font-weight: bold;
  z-index: 10;
  transform: translateY(150%);
  transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.sheet-broken-overlay.visible {
  transform: translateY(0);
}

.sheet-broken-title {
  color: #b91c1c;
  font-size: 12px;
  font-weight: 800;
  margin-bottom: 4px;
  text-transform: uppercase;
  display: flex;
  align-items: center;
  gap: 4px;
}

@media (max-width: 900px) {
  .hero {
    grid-template-columns: 1fr;
    gap: 32px;
    padding: 40px 24px;
  }
}

/* ─── PROBLEM ─── */
.problem-cols {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
  margin-top: 36px;
  position: relative;
}

/* Connecting bridge line that appears on hover of any box */
.problem-cols::after {
  content: '';
  position: absolute;
  top: 50%;
  left: calc(50% - 16px);
  width: 32px;
  height: 4px;
  background: var(--text);
  opacity: 0;
  transition: opacity 0.2s ease-in-out;
  transform: translateY(-50%) skewX(-6deg);
  z-index: 1;
}

.problem-cols:hover::after {
  opacity: 1;
}

.prob-col {
  background: #ffffff;
  border: 3px solid var(--text); /* Thicker borders */
  padding: 24px 32px; /* Reduced padding for lower height */
  position: relative;
  transform: skewX(-6deg);
  transition: all 0.2s ease-in-out;
  z-index: 2;
}

.prob-col > * {
  transform: skewX(6deg); /* Un-skew the content so text remains readable */
}

.prob-col strong {
  display: block;
  font-size: 16px;
  font-weight: 800;
  margin-bottom: 8px;
  color: var(--text);
}

.prob-col p { 
  font-size: 13.5px; 
  color: #444; 
  line-height: 1.5;
}

.prob-col:hover {
  background: var(--green);
  color: #ffffff !important;
  transform: skewX(-6deg); /* Don't shift up/translate so bridge line connects cleanly */
}

.prob-col:hover strong, .prob-col:hover p {
  color: #ffffff !important;
}

/* ─── FULL-WIDTH GRID DESIGN (WHO IT HELPS) ─── */
.helps-section {
  border-top: var(--rule);
  padding: 0 !important;
  max-width: 100% !important;
}

.helps-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  width: 100%;
  border-bottom: 1px solid #E5E5E0;
}

/* Pricing Grid Hover & Highlight overrides to prevent bad contrast states */
.pricing-grid .helps-cell {
  cursor: default;
  background: #ffffff !important;
  border-color: #E5E5E0 !important;
  box-shadow: none;
  transform: none;
  transition: all 0.15s ease-in-out;
}

.pricing-grid .helps-cell:hover {
  background: #ffffff !important;
  color: var(--text) !important;
  box-shadow: 6px 6px 0px 0px var(--text) !important;
  transform: translate(-3px, -3px) !important;
}

.pricing-grid .helps-cell:hover p,
.pricing-grid .helps-cell:hover .helps-role,
.pricing-grid .helps-cell:hover .helps-stage,
.pricing-grid .helps-cell:hover li,
.pricing-grid .helps-cell:hover span,
.pricing-grid .helps-cell:hover strong {
  color: var(--text) !important;
}

.pricing-grid .helps-cell:hover .helps-header {
  border-bottom-color: #E5E5E0 !important;
}

/* Specific override for active lists and checks on pricing hover */
.pricing-grid .helps-cell ul li span {
  color: var(--green) !important;
}

/* ─── HOW IT WORKS FLOW DIAGRAM ─── */
.flow-section {
  border-top: var(--rule);
  padding: 0 !important;
  max-width: 100% !important;
}

.flow-container {
  width: 100%;
  background: var(--bg);
  border-bottom: var(--rule);
  padding: 48px;
  display: flex;
  flex-direction: column;
  align-items: center;
  position: relative;
  overflow: hidden;
}

/* Rows */
.flow-row {
  display: flex;
  justify-content: space-around;
  width: 100%;
  max-width: 960px;
  position: relative;
  z-index: 2;
}

/* Inputs (Bottom) -> Core (Middle) -> Outputs (Top) */
.flow-node {
  background: #ffffff;
  border: 2px solid var(--text);
  box-shadow: 4px 4px 0px 0px var(--text);
  padding: 18px 24px;
  border-radius: 4px;
  width: 220px;
  text-align: center;
  transition: all 0.15s ease-in-out;
}

.flow-node:hover {
  background: var(--yellow);
  box-shadow: 6px 6px 0px 0px var(--text);
  transform: translate(-1.5px, -1.5px);
}

.flow-node.core-hub {
  border: 3px solid var(--text);
  background: #ffffff;
  width: 320px;
  box-shadow: 6px 6px 0px 0px var(--text);
}

.flow-node.core-hub:hover {
  background: var(--green);
  color: #ffffff;
}

.flow-node.core-hub:hover h4 {
  color: #ffffff;
}

.flow-node h4 {
  font-size: 13px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--green);
  margin-bottom: 6px;
}

.flow-node p {
  font-size: 12px;
  color: #555;
  line-height: 1.4;
}

.flow-node:hover p {
  color: inherit;
}

/* Left diagram specific layouts */
.diagram-wrapper {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 48px;
  position: relative;
  width: 100%;
  max-width: 360px;
  z-index: 2;
}

.diagram-node {
  background: #ffffff;
  border: 2px solid var(--text);
  box-shadow: 4px 4px 0px 0px var(--text);
  padding: 14px;
  border-radius: 4px;
  width: 140px;
  text-align: center;
  z-index: 2;
  transition: all 0.15s ease-in-out;
  flex-shrink: 0;
}

.diagram-node.core-hub {
  border: 3px solid var(--text);
  box-shadow: 6px 6px 0px 0px var(--text);
  background: #ffffff;
}

.diagram-node.core-hub h4 {
  font-size: 13px;
  font-weight: 800;
  color: var(--green);
  margin-bottom: 4px;
}

.diagram-node.core-hub p {
  font-size: 11px;
  font-weight: 600;
  color: #555;
  line-height: 1.2;
}

.diagram-destinations {
  display: flex;
  flex-direction: column;
  gap: 12px;
  width: 140px;
  position: relative;
  flex-shrink: 0;
}

.diagram-dest-item {
  background: #ffffff;
  border: 1.5px solid var(--text);
  box-shadow: 2px 2px 0px 0px var(--text);
  padding: 8px;
  font-family: monospace;
  font-size: 10px;
  font-weight: bold;
  text-align: center;
  border-radius: 2px;
  color: var(--text);
}

/* Connecting Vectors (SVG Overlay) */
.flow-vectors {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 1;
}

.flow-vector-line {
  fill: none;
  stroke: var(--text);
  stroke-width: 2px;
}

.flow-arrow-head {
  fill: var(--text);
}

@media (max-width: 900px) {
  .flow-container {
    grid-template-columns: 1fr;
  }
  .flow-left-pane {
    border-right: none;
    border-bottom: var(--rule);
    padding: 48px 24px;
  }
  .flow-desc-row {
    padding: 24px;
  }
}

/* 3-column Grid specifically for Pricing Tiers to prevent row overflow */
.pricing-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  width: 100%;
  gap: 32px;
  padding: 0 48px 48px;
}

.pricing-grid .helps-cell {
  border: 3px solid #111;
  box-shadow: 6px 6px 0px 0px #111;
  background: #fff;
  transition: all 0.15s ease-in-out;
}

.pricing-grid .helps-cell:hover {
  background: var(--green) !important;
  color: #ffffff !important;
}

.pricing-grid .helps-cell:hover p,
.pricing-grid .helps-cell:hover .helps-role,
.pricing-grid .helps-cell:hover .helps-stage {
  color: #ffffff !important;
}

.helps-cell {
  padding: 64px 48px;
  border-right: 1px solid #E5E5E0;
  border-top: 1px solid #E5E5E0;
  background: var(--bg);
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: 280px;
  transition: all 0.2s ease-in-out;
  cursor: default;
}

.helps-cell:nth-child(even) {
  border-right: none;
}

.helps-cell:hover {
  background: var(--green);
  color: #FFFFFF !important;
}

.helps-cell:hover p, .helps-cell:hover .helps-role, .helps-cell:hover em {
  color: #FFFFFF !important;
}

.helps-cell:hover a {
  color: #FFFFFF !important;
  border-bottom-color: #FFFFFF !important;
}

.helps-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 20px;
  border-bottom: 1px solid #E5E5E0;
  padding-bottom: 12px;
}

.helps-cell:hover .helps-header {
  border-bottom-color: rgba(255, 255, 255, 0.25);
}

.helps-role {
  font-size: 18px;
  font-weight: 800;
  letter-spacing: -0.01em;
  color: var(--text);
  transition: color 0.2s ease-in-out;
}

.helps-cell p {
  font-size: 16px;
  color: #333;
  line-height: 1.65;
  margin-bottom: 0;
  flex-grow: 1;
}

@media (max-width: 768px) {
  .helps-grid {
    grid-template-columns: 1fr;
  }
  .helps-cell {
    border-right: none;
    padding: 28px;
    min-height: auto;
  }
}

/* ─── FAQ ─── */
.faq-item {
  border-top: 1px solid #CCC;
  padding: 18px 0;
}

.faq-item:last-child { border-bottom: 1px solid #CCC; }

.faq-q {
  font-size: 15px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 8px;
  letter-spacing: -0.01em;
}

.faq-a {
  font-size: 14px;
  color: #555;
  line-height: 1.65;
  max-width: 700px;
}

/* ─── PARTNERS ─── */
.partner-block {
  padding: 28px 0;
  border-top: 1px solid #DDD;
}

.partner-block:first-of-type { border-top: none; margin-top: 24px; }

.partner-header {
  display: flex;
  align-items: baseline;
  gap: 20px;
  margin-bottom: 10px;
}

.partner-name {
  font-size: 17px;
  font-weight: 800;
  letter-spacing: -0.01em;
}

.partner-tag {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--green);
}

.partner-block p { font-size: 14px; color: #555; max-width: 680px; line-height: 1.65; }

.partner-list {
  margin-top: 12px;
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0;
}

.partner-list li {
  font-size: 13px;
  color: #444;
  padding: 5px 16px 5px 0;
  margin-right: 16px;
  border-right: 1px solid #CCC;
  line-height: 1.4;
}

.partner-list li:last-child { border-right: none; }

/* ─── PRICING TABLE ─── */
.pricing-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 24px;
  font-size: 13.5px;
}

.pricing-table th {
  text-align: left;
  padding: 12px 16px;
  border: var(--rule);
  background: #F0F0EC;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: #666;
}

.pricing-table th.plan-head {
  text-align: center;
  font-size: 13px;
  color: var(--text);
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: none;
}

.pricing-table td {
  padding: 11px 16px;
  border: 1px solid #CCC;
  vertical-align: middle;
  color: #444;
  line-height: 1.4;
}

.pricing-table td.center { text-align: center; }

.pricing-table .yes { color: var(--green); font-weight: 800; font-size: 15px; }
.pricing-table .no { color: #BBB; font-weight: 700; font-size: 14px; }

.pricing-table .section-row td {
  background: #F0F0EC;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: #888;
  padding: 8px 16px;
}

.pricing-table .price-row td {
  font-size: 20px;
  font-weight: 800;
  letter-spacing: -0.02em;
  border-top: var(--rule);
}

.pricing-table .price-row td.center {
  font-size: 16px;
  color: #555;
  font-weight: 700;
}

.badge {
  display: inline-block;
  background: var(--yellow);
  color: var(--text);
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 2px 6px;
  margin-left: 6px;
  vertical-align: middle;
}

/* ─── CONTACT FORM (Anti-Design Boxy) ─── */
.contact-section {
  border-top: var(--rule);
  padding: 0 !important;
  max-width: 100% !important;
}

.contact-inner {
  max-width: 720px;
  margin: 0 auto;
  padding: 64px 48px;
}

.contact-box {
  background: #ffffff;
  border: 3px solid var(--text);
  box-shadow: 8px 8px 0px 0px var(--text);
  padding: 40px;
  position: relative;
}

.contact-box h2 {
  color: var(--text);
  margin-bottom: 8px;
  font-size: 22px;
}

.contact-box > p {
  font-size: 15px;
  color: #555;
  margin-bottom: 28px;
  line-height: 1.6;
}

.contact-field {
  margin-bottom: 20px;
}

.contact-field label {
  display: block;
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text);
  margin-bottom: 6px;
}

.contact-field input,
.contact-field select,
.contact-field textarea {
  width: 100%;
  padding: 12px 14px;
  border: 2px solid var(--text);
  background: #ffffff;
  font-family: inherit;
  font-size: 14px;
  color: var(--text);
  outline: none;
  transition: all 0.15s ease-in-out;
  box-shadow: 2px 2px 0px 0px transparent;
}

.contact-field input:focus,
.contact-field select:focus,
.contact-field textarea:focus {
  box-shadow: 3px 3px 0px 0px var(--text);
  transform: translate(-1.5px, -1.5px);
}

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

.contact-msg {
  display: none;
  padding: 12px 14px;
  border: 2px solid;
  margin-bottom: 20px;
  font-size: 13px;
  font-weight: 600;
}

.contact-msg.success {
  display: block;
  background: #f0fdf4;
  border-color: var(--green);
  color: var(--green);
}

.contact-msg.error {
  display: block;
  background: #fffbeb;
  border-color: var(--yellow);
  color: #92400e;
}

.contact-submit {
  font-family: inherit;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 12px 24px;
  border: 2px solid var(--text);
  background: var(--green);
  color: #FFFFFF;
  cursor: pointer;
  box-shadow: 4px 4px 0px 0px var(--text);
  transition: all 0.15s ease-in-out;
  width: 100%;
}

.contact-submit:hover {
  background: var(--yellow);
  color: var(--text);
  box-shadow: 6px 6px 0px 0px var(--text);
  transform: translate(-2px, -2px);
}

/* Appendix link styles */
.appendix-link {
  font-size: 14px;
  color: var(--text);
  text-decoration: none;
  transition: all 0.15s ease-in-out;
}

.appendix-link:hover {
  color: var(--green);
  font-weight: 700;
}

@media (max-width: 768px) {
  /* Fold 2 - Spreadsheet section */
  section[style*="grid-template-columns: 1fr 1fr"] > div[style*="display: grid"] {
    display: block !important;
  }
  
  section[style*="grid-template-columns: 1fr 1fr"] > div > div {
    padding: 32px 24px !important;
    min-height: auto !important;
  }
  
  .hero-sheet {
    max-width: 100% !important;
    overflow-x: auto;
    margin-top: 32px !important;
  }
  
  .sheet-grid {
    min-width: 320px;
    font-size: 12px;
  }
  
  .sheet-cell {
    font-size: 11px !important;
    padding: 8px !important;
  }
  
  /* Fold 3 - How it works */
  div[style*="grid-template-columns: repeat(4, 1fr)"] {
    grid-template-columns: 1fr !important;
    gap: 16px !important;
  }
  
  /* Hide SVG connections on mobile */
  svg[viewBox="0 0 1200 80"] {
    display: none !important;
  }
  
  /* Adjust hub margin on mobile */
  div[style*="margin-bottom: 80px"] {
    margin-bottom: 32px !important;
  }
  
  /* Pricing section */
  .pricing-grid {
    grid-template-columns: 1fr !important;
    padding: 0 24px 32px !important;
  }
  
  .pricing-grid .helps-cell {
    margin-bottom: 16px;
  }
  
  /* Appendix section */
  div[style*="grid-template-columns: repeat(4, 1fr)"][style*="margin: 48px"] {
    grid-template-columns: 1fr !important;
    margin: 24px !important;
    gap: 16px !important;
  }
  
  /* General mobile fixes */
  .problem-cols { 
    grid-template-columns: 1fr; 
  }
  
  .prob-col, .prob-col:last-child, .prob-col:nth-child(2) { 
    border-right: none; 
    border-top: 1px solid #DDD; 
    padding: 20px 0; 
  }
  
  .cta-row { 
    flex-direction: column; 
    align-items: flex-start; 
  }
  
  .nav-right a:not(.nav-cta) { 
    display: none; 
  }
  
  /* Adjust padding for mobile */
  section {
    padding: 32px 24px !important;
  }
  
  .contact-inner {
    padding: 32px 24px !important;
  }
}
