:root {
  --bg: #f8fafc;
  --surface: #ffffff;
  --text: #1e293b;
  --muted: #64748b;
  --line: #e2e8f0;
  --primary: #2f7fca;
  --primary-soft: #57a3f5;
}

html, body {
  margin: 0;
  padding: 0;
  min-height: 100%;
  width: 100%;
  font-family: "Roboto", sans-serif;
  background-color: var(--bg);
  color: var(--text);
}

* { box-sizing: border-box; }

a {
  text-decoration: none;
  color: inherit;
}


/* ================================
   NAVBAR — UNCHANGED
   ================================ */

#navbar {
  position: absolute;
  top: 20px;
  left: 30px;
  display: flex;
  flex-direction: row;
  justify-content: flex-start;
  align-items: center;
  width: auto;
  font-family: "Roboto", sans-serif;
  gap: 0;
  z-index: 5;
}

.navknapper {
  float: none;
  display: inline-block;
  font-size: 14px;
  color: #1e293b;
  text-align: center;
  padding: 8px 16px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-weight: 700;
  transition: all 0.3s ease;
  white-space: nowrap;
  border-radius: 6px;
}

.navknapper:hover {
  color: #57a3f5;
  transform: translateY(-2px);
}

#hjemknapp {
  background-color: white;
  font-size: 14px;
  color: #1e293b;
  text-align: center;
  padding: 2px 16px;
  border: 2px solid #1e293b;
  border-radius: 5px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-weight: 700;
  cursor: pointer;
  transition: background-color 0.5s, color 0.5s, transform 0.4s ease-in-out;
}

#hjemknapp:hover {
  background-color: #1e293b;
  color: white;
}


/* ================================
   PAGE LAYOUT
   ================================ */

#main {
  padding: 100px 24px 80px;
  display: flex;
  justify-content: center;
}

.ses-container {
  width: 100%;
  max-width: 780px;
  display: flex;
  flex-direction: column;
  gap: 28px;
}


/* ================================
   HERO
   ================================ */

.ses-hero {
  text-align: center;
}

.ses-eyebrow {
  display: block;
  font-size: clamp(1.1rem, 2.5vw, 1.3rem);
  font-weight: 400;
  font-style: italic;
  color: #1e293b;
  margin: 0 0 6px;
}

.ses-title {
  font-size: clamp(2.8rem, 7vw, 4.5rem);
  font-weight: 800;
  color: var(--primary-soft);
  margin: 0 0 16px;
  line-height: 1.05;
  letter-spacing: -2px;
}

.ses-sub {
  color: var(--muted);
  font-size: 1rem;
  line-height: 1.75;
  margin: 0 auto;
  max-width: 480px;
}


/* ================================
   FEATURES ROW
   ================================ */

.ses-features {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  gap: 14px;
}

.ses-feature {
  flex: 1;
  display: flex;
  align-items: flex-start;
  gap: 12px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 16px;
}

.ses-feature-icon {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: #eff6ff;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-size: 1.15rem;
}

.ses-feature-icon ion-icon {
  font-size: 1.15rem;
  color: var(--primary-soft);
  opacity: 1;
  position: static;
}

.ses-feature-text strong {
  display: block;
  font-size: 0.85rem;
  color: var(--text);
  font-weight: 700;
  margin-bottom: 2px;
}

.ses-feature-text span {
  font-size: 0.78rem;
  color: var(--muted);
  line-height: 1.45;
}


/* ================================
   FORM CARD
   ================================ */

.ask-card {
  background: #ffffff;
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 28px;
  box-shadow: 0 4px 14px rgba(15, 23, 42, 0.05);
}


/* ================================
   FORM FIELDS
   ================================ */

.field-grid {
  display: grid;
  gap: 14px;
  margin-bottom: 14px;
}

.two-cols {
  grid-template-columns: 1fr 1fr;
}

.field {
  width: 100%;
  display: flex;
  flex-direction: column;
}

.field label {
  display: block;
  font-size: 0.76rem;
  font-weight: 700;
  color: #475569;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  margin-bottom: 7px;
}

.input-wrapper {
  position: relative;
}

.input-wrapper ion-icon {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: #94a3b8;
  pointer-events: none;
  opacity: 0.6;
  font-size: 1.3rem;
}

#askForm input,
#askForm textarea {
  width: 100%;
  padding: 11px 40px 11px 13px;
  border: 1px solid #cbd5e1;
  border-radius: 10px;
  font-family: "Roboto", sans-serif;
  font-size: 15px;
  line-height: 1.35;
  background: #fff;
  color: var(--text);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
  outline: none;
}

#askForm textarea {
  resize: vertical;
  min-height: 160px;
  padding: 11px 13px;
  line-height: 1.55;
}

#askForm input::placeholder,
#askForm textarea::placeholder {
  color: #94a3b8;
}

#askForm input:focus,
#askForm textarea:focus {
  border-color: #57a3f5;
  box-shadow: 0 0 0 4px rgba(87, 163, 245, 0.15);
}

.field:has(textarea) {
  margin-top: 14px;
}

.field-hint {
  display: flex;
  justify-content: flex-end;
  margin-top: 6px;
  color: #94a3b8;
  font-size: 0.78rem;
}

#charCount {
  white-space: nowrap;
}


/* ================================
   SUBMIT SLOT
   ================================ */

.ask-actions {
  position: relative;
  width: 100%;
  min-height: 52px;
  margin-top: 20px;
}

.ask-actions #submit-btn,
.ask-actions #alert {
  width: 100%;
}

.ask-submit {
  width: 100%;
  appearance: button;
  background-color: var(--primary);
  border: solid transparent;
  border-radius: 8px;
  border-width: 0 0 4px;
  box-sizing: border-box;
  color: #fff;
  cursor: pointer;
  display: inline-block;
  font-family: "Roboto", sans-serif;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.06em;
  line-height: 20px;
  outline: none;
  padding: 13px 16px;
  text-align: center;
  text-transform: uppercase;
  transform: translateZ(0);
  transition: filter 0.2s;
  user-select: none;
  vertical-align: middle;
  white-space: nowrap;
  position: relative;
  -webkit-tap-highlight-color: transparent;
}

.ask-submit::after {
  background-clip: padding-box;
  background-color: var(--primary-soft);
  border: solid transparent;
  border-radius: 8px;
  border-width: 0 0 4px;
  bottom: -4px;
  content: "";
  left: 0;
  position: absolute;
  right: 0;
  top: 0;
  z-index: -1;
}

.ask-submit:hover:not(:disabled) {
  filter: brightness(1.04);
}

.ask-submit:active {
  border-width: 4px 0 0;
  background: none;
}

.ask-submit:disabled {
  cursor: auto;
}

#submit-btn.is-loading {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

#submit-btn.is-loading::before {
  content: "";
  width: 14px;
  height: 14px;
  border: 2px solid rgba(255, 255, 255, 0.45);
  border-top-color: #fff;
  border-radius: 50%;
  animation: submitSpinner 0.7s linear infinite;
}

@keyframes submitSpinner {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

#alert {
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  text-align: center;
  display: none;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  height: 93%;
  padding: 0 20px;
  line-height: 1.2;
  background: #79c879;
  color: #fff;
  border-radius: 6px;
  border: 1px solid rgba(255, 255, 255, 0.25);
  z-index: 2;
}


/* ================================
   RESPONSIVE
   ================================ */

@media (max-width: 768px) {
  #main {
    padding: 84px 16px 60px;
  }

  .ses-container {
    gap: 20px;
  }

  .ask-card {
    padding: 20px;
    border-radius: 14px;
  }

  .two-cols {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 560px) {
  .ses-features {
    flex-direction: column;
  }
}
