/* Beygir Bet — embed form */
:root {
  --bg-base: #0a1d3f;
  --grad-start: #093482;
  --grad-end: #041d4a;
  --accent: #00d4ff;
  --accent-soft: rgba(0, 212, 255, 0.14);
  --text: #e8f4ff;
  --text-muted: #8fb3d9;
  --border: rgba(0, 212, 255, 0.25);
  --radius: 14px;
  --font: "DM Sans", system-ui, sans-serif;
  --shadow: 0 16px 40px rgba(0, 0, 0, 0.28);
  /* Ana sitedeki alt menü iframe’i kapatıyorsa artırın (örn. 6rem, 7rem) */
  --embed-safe-bottom: 5.5rem;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  overflow-x: hidden;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  height: 100%;
}

body.embed {
  margin: 0;
  min-height: 100%;
  font-family: var(--font);
  font-size: 15px;
  color: var(--text);
  line-height: 1.55;
  background-color: var(--bg-base);
  background-image: linear-gradient(165deg, var(--grad-start), var(--grad-end));
  background-attachment: scroll;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.shell {
  max-width: 520px;
  margin: 0 auto;
  padding: 1.25rem 1rem calc(1.5rem + var(--embed-safe-bottom));
  width: 100%;
}

.panel {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.panel-head {
  padding: 1.35rem 1.25rem 1.1rem;
  text-align: center;
}

.panel-head h1 {
  margin: 0 0 0.5rem;
  font-size: clamp(1.3rem, 4.5vw, 1.6rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.25;
  color: var(--text);
}

.panel-lead {
  margin: 0 auto;
  max-width: 26rem;
  font-size: 0.9rem;
  color: var(--text-muted);
}

.panel-divider {
  height: 1px;
  margin: 0 1.15rem;
  background: var(--border);
}

.panel-body {
  padding: 1.15rem 1.25rem 1.35rem;
}

#feedback-form {
  position: relative;
}

.field-label {
  display: block;
  margin-bottom: 0.4rem;
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--text-muted);
}

.field-label-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  margin-bottom: 0.4rem;
}

.field-label-row .field-label {
  margin-bottom: 0;
}

.optional {
  font-weight: 400;
  color: var(--text-faint);
}

.char-count {
  font-size: 0.72rem;
  color: var(--text-faint);
  font-variant-numeric: tabular-nums;
}

.char-count.is-valid {
  color: var(--accent);
}

/* Tür seçici */
.type-picker {
  margin: 0 0 1rem;
  padding: 0;
  border: none;
}

.type-picker legend {
  padding: 0;
}

.type-picker-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.55rem;
}

.type-option {
  cursor: pointer;
}

.type-option input {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
}

.type-option-face {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  padding: 0.7rem 0.5rem;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text-muted);
  background: var(--input-bg);
  border: 1px solid var(--border);
  border-radius: 10px;
  transition: border-color 0.2s, color 0.2s, background 0.2s;
}

.type-option:hover .type-option-face {
  color: var(--text);
  border-color: rgba(0, 212, 255, 0.35);
}

.type-option input:focus-visible + .type-option-face {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.type-option input:checked + .type-option-face {
  color: var(--text);
  background: var(--accent-soft);
  border-color: var(--accent);
}

.type-option input:checked + .type-option-face svg {
  color: var(--accent);
}

.field-grid {
  display: grid;
  gap: 0.8rem;
}

@media (min-width: 440px) {
  .field-grid--2 {
    grid-template-columns: 1fr 1fr;
  }
}

.field {
  margin-bottom: 0.8rem;
}

.input-wrap {
  position: relative;
}

.input-icon {
  position: absolute;
  left: 0.8rem;
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  color: var(--text-faint);
  pointer-events: none;
}

.input-wrap:focus-within .input-icon {
  color: var(--accent);
}

.input-wrap input,
.input-wrap textarea {
  width: 100%;
  padding: 0.7rem 0.85rem 0.7rem 2.5rem;
  font-family: inherit;
  font-size: 0.92rem;
  color: var(--text);
  background: var(--input-bg);
  border: 1px solid var(--border);
  border-radius: 10px;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.input-wrap--area textarea {
  padding: 0.8rem 0.85rem;
  min-height: 120px;
  resize: vertical;
  line-height: 1.5;
}

.input-wrap input::placeholder,
.input-wrap textarea::placeholder {
  color: rgba(232, 244, 255, 0.38);
}

.input-wrap input:focus,
.input-wrap textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}

.hp-field {
  position: absolute;
  left: -9999px;
  opacity: 0;
  pointer-events: none;
}

.consent {
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  margin-bottom: 1rem;
  cursor: pointer;
}

.consent input {
  margin-top: 0.2rem;
  width: 1rem;
  height: 1rem;
  accent-color: var(--accent);
  flex-shrink: 0;
  cursor: pointer;
}

.consent-box {
  display: none;
}

.consent-text {
  font-size: 0.78rem;
  color: var(--text-muted);
  line-height: 1.45;
}

.btn-submit {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  width: 100%;
  padding: 0.85rem 1.2rem;
  font-family: inherit;
  font-size: 0.95rem;
  font-weight: 600;
  color: #041d4a;
  background: linear-gradient(135deg, var(--accent), #33ddff);
  border: none;
  border-radius: 10px;
  cursor: pointer;
  box-shadow: 0 6px 20px rgba(0, 212, 255, 0.22);
  transition: transform 0.15s ease, box-shadow 0.2s ease;
}

.btn-submit:hover:not(:disabled) {
  transform: translateY(-1px);
  box-shadow: 0 8px 24px rgba(0, 212, 255, 0.3);
}

.btn-submit:disabled {
  opacity: 0.65;
  cursor: not-allowed;
}

.btn-submit .spinner {
  width: 1rem;
  height: 1rem;
  border: 2px solid rgba(4, 29, 74, 0.3);
  border-top-color: #041d4a;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
  display: none;
}

.btn-submit.loading .spinner {
  display: block;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.form-status {
  margin-top: 0.85rem;
  padding: 0.75rem 0.9rem;
  border-radius: 10px;
  font-size: 0.85rem;
  display: none;
}

.form-status.visible {
  display: block;
}

.form-status.success {
  background: rgba(0, 200, 120, 0.15);
  border: 1px solid rgba(0, 200, 120, 0.4);
  color: #7fefc0;
}

.form-status.error {
  background: rgba(255, 100, 100, 0.12);
  border: 1px solid rgba(255, 120, 120, 0.35);
  color: #ffb4b4;
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

@media (prefers-reduced-motion: reduce) {
  .btn-submit,
  .type-option-face,
  .input-wrap input,
  .input-wrap textarea {
    transition: none;
  }

  .btn-submit .spinner {
    animation: none;
  }
}
