/* join.ktown.team — minimal */

:root {
  --navy: #070A61;
  --bg: #FAFAFA;
  --text: #070A61;
  --text-light: #8A8DB5;
  --border: #E0E0E0;
  --card-bg: #FFFFFF;
  --green: #2D8C5C;
  --red: #C45454;
  --blue: #0075F2;
}

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

body {
  font-family: 'Sofia Pro', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

a { color: var(--text); text-decoration: none; }

/* Header */
.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.6rem 1.5rem;
  border-bottom: 1px solid var(--border);
}

.site-logo {
  font-family: 'Cubano', sans-serif;
  font-size: 1rem;
  color: var(--navy);
  text-decoration: none;
  letter-spacing: 0.03em;
}
.site-logo span { font-weight: 400; }

.header-actions { display: flex; align-items: center; }
.lang-switch { display: flex; gap: 0.4rem; }
.lang-switch a {
  color: var(--text-light);
  font-size: 0.8rem;
  padding: 0.15rem 0.5rem;
}
.lang-switch a.current { color: var(--navy); }
.lang-switch a:hover { color: var(--navy); }

/* Main */
main {
  flex: 1;
  max-width: 720px;
  width: 100%;
  margin: 0 auto;
  padding: 2rem 1.5rem 3rem;
}

/* Hero section */
.hero-section {
  text-align: center;
  margin-bottom: 2.5rem;
}
.hero-section h1 {
  font-family: 'Cubano', sans-serif;
  font-size: 2rem;
  font-weight: 700;
  color: var(--navy);
  margin-bottom: 0.5rem;
}
.subtitle {
  font-size: 1.05rem;
  color: var(--text);
  margin-bottom: 0.75rem;
}
.intro {
  font-size: 0.9rem;
  color: var(--text-light);
  max-width: 560px;
  margin: 0 auto;
}

/* Services section */
.services-section {
  margin-bottom: 2.5rem;
}
.services-section h2 {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-light);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 0.75rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid var(--border);
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0;
  border: 1px solid var(--border);
  border-radius: 6px;
  overflow: hidden;
  background: var(--card-bg);
}

.service-card {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.7rem 0.85rem;
  border-bottom: 1px solid var(--border);
  border-right: 1px solid var(--border);
  color: var(--text);
  text-decoration: none;
  transition: background 0.15s;
}
.service-card:hover { background: var(--bg); }
.service-card:nth-child(3n) { border-right: none; }
.service-card:nth-last-child(-n+3) { border-bottom: none; }
/* Handle uneven last row */
.service-card:nth-last-child(1):nth-child(3n+1),
.service-card:nth-last-child(2):nth-child(3n+1),
.service-card:nth-last-child(2):nth-child(3n+1) ~ .service-card { border-bottom: none; }

.service-icon {
  color: var(--text-light);
  display: flex;
  flex-shrink: 0;
}
.service-name {
  font-size: 0.8rem;
  font-weight: 500;
}

/* Form section */
.form-section {
  margin-bottom: 2rem;
}
.form-section h2 {
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 0.25rem;
}
.form-subtitle {
  font-size: 0.85rem;
  color: var(--text-light);
  margin-bottom: 1.5rem;
}

.field {
  margin-bottom: 1.25rem;
}
.field label {
  display: block;
  font-size: 0.8rem;
  font-weight: 600;
  margin-bottom: 0.3rem;
  color: var(--text);
}

.field input[type="text"],
.field input[type="email"],
.field input[type="tel"] {
  width: 100%;
  font-family: inherit;
  font-size: 0.85rem;
  padding: 0.55rem 0.75rem;
  border: 1px solid var(--border);
  border-radius: 5px;
  outline: none;
  background: var(--card-bg);
  color: var(--text);
}
.field input:focus { border-color: var(--text-light); }

/* Roles */
.roles-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.role-option {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.8rem;
  cursor: pointer;
  padding: 0.35rem 0.65rem;
  border: 1px solid var(--border);
  border-radius: 4px;
  transition: border-color 0.15s, background 0.15s;
  user-select: none;
}
.role-option:hover { border-color: var(--text-light); }
.role-option input { display: none; }
.role-option:has(input:checked) {
  border-color: var(--navy);
  background: rgba(7,10,97,0.05);
}

/* Submit */
.submit-btn {
  display: block;
  width: 100%;
  font-family: inherit;
  font-size: 0.9rem;
  font-weight: 600;
  padding: 0.7rem;
  border: none;
  border-radius: 5px;
  background: var(--blue);
  color: #fff;
  cursor: pointer;
  margin-top: 0.5rem;
}
.submit-btn:hover { opacity: 0.9; }
.submit-btn:disabled { opacity: 0.4; cursor: not-allowed; }

/* Messages */
.form-message {
  margin-top: 0.75rem;
  font-size: 0.8rem;
  text-align: center;
}
.form-message.error { color: var(--red); }
.form-message.info { color: var(--blue); }

/* Success panel */
.success-panel {
  text-align: center;
  padding: 2rem 0;
}
.success-icon {
  color: var(--green);
  margin-bottom: 1rem;
}
.success-panel h2 {
  font-size: 1.3rem;
  margin-bottom: 0.5rem;
}
.success-panel p {
  font-size: 0.9rem;
  color: var(--text-light);
}

/* Footer */
.site-footer {
  border-top: 1px solid var(--border);
  padding: 1rem 1.5rem;
  text-align: center;
}
.footer-links {
  display: flex;
  justify-content: center;
  gap: 1rem;
  flex-wrap: wrap;
  margin-bottom: 0.5rem;
}
.footer-links a {
  color: var(--text-light);
  font-size: 0.75rem;
}
.footer-links a:hover { color: var(--text); }
.site-footer p {
  font-size: 0.7rem;
  color: var(--text-light);
}
.site-footer p a { color: var(--text-light); }

/* Dark mode — opt-in via class */
html.dark {
  --navy: #FFFFFF;
  --bg: #000000;
  --text: #E0E0E0;
  --text-light: #666;
  --border: #1A1A1A;
  --card-bg: #0A0A0A;
  --green: #4ADE80;
  --red: #F87171;
  --blue: #4DA3FF;
}
html.dark .field input {
  background: #0A0A0A;
  color: var(--text);
}
html.dark .submit-btn {
  background: #E0E0E0;
  color: #000;
}
html.dark .submit-btn:hover { background: #FFF; }
html.dark .role-option:has(input:checked) {
  border-color: #E0E0E0;
  background: rgba(255,255,255,0.05);
}
html.dark .service-card:hover { background: #111; }

/* Mobile */
@media (max-width: 600px) {
  .site-header { padding: 0.5rem 1rem; }
  main { padding: 1.5rem 1rem 2rem; }
  .hero-section h1 { font-size: 1.5rem; }
  .services-grid { grid-template-columns: repeat(2, 1fr); }
  .service-card:nth-child(3n) { border-right: 1px solid var(--border); }
  .service-card:nth-child(2n) { border-right: none; }
  .service-card:nth-last-child(-n+3) { border-bottom: 1px solid var(--border); }
  .service-card:nth-last-child(-n+2) { border-bottom: none; }
}
