/* =========================================================================
   Arab Arena — forms & cards in the platform.mechaml.com style
   (soft 28px panels, quiet #fcfcff fields, small labels, numbered sections,
    dark pill submit). Loaded after app.css / admin.css / fixes.css.
   ========================================================================= */
:root {
  --f-bg: #fcfcff; --f-line: #dfe1ea; --f-line-h: #c9d4f8; --f-label: #3d4154;
  --f-card-shadow: 0 15px 55px #202c5507; --f-r: 12px;
}

/* ---------- fields ---------- */
input:where(:not([type=checkbox]):not([type=radio]):not([type=range]):not([type=file]):not(.tf-input):not(.hp)),
select, textarea:where(:not(.tf-input):not(#prompt)) {
  background-color: var(--f-bg);
  border: 1px solid var(--f-line);
  border-radius: var(--f-r);
  min-height: 48px;
  padding: 12px 14px;
  font-size: 14.5px;
  line-height: 1.6;
  color: var(--ink);
  box-shadow: none;
  transition: border-color .18s, box-shadow .18s, background-color .18s;
}
input:where(:not([type=checkbox]):not([type=radio]):not([type=range]):not([type=file]):not(.tf-input):not(.hp)):hover, select:hover, textarea:where(:not(.tf-input):not(#prompt)):hover { border-color: var(--f-line-h); }
input:where(:not([type=checkbox]):not([type=radio]):not([type=range]):not([type=file]):not(.tf-input):not(.hp)):focus, select:focus, textarea:where(:not(.tf-input):not(#prompt)):focus {
  background-color: #fff; border-color: var(--blue); box-shadow: 0 0 0 4px #3563e914; outline: none;
}
input::placeholder, textarea::placeholder { color: #a7abb9; }
textarea:where(:not(.tf-input):not(#prompt)) { min-height: 112px; resize: vertical; }
/* one consistent chevron for every select (left side, RTL) */
select:where(:not([multiple])) {
  -webkit-appearance: none; appearance: none;
  padding-inline-end: 40px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5l5 5 5-5' fill='none' stroke='%2319192d' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: left 15px center; background-size: 12px 8px;
}
[dir=ltr] select:where(:not([multiple])), select[dir=ltr] { background-position: right 15px center; }
input[readonly] { background-color: #f5f6fa; }

/* labels: small, quiet, above the field */
label { font-size: 13px; font-weight: 500; color: var(--f-label); gap: 8px; line-height: 1.6; }
label > input:not([type=checkbox]):not([type=radio]), label > select, label > textarea { margin-top: 0; font-weight: 400; }

/* checkboxes & radios */
input[type=checkbox], input[type=radio] {
  -webkit-appearance: none; appearance: none; width: 18px; height: 18px; min-height: 0; flex-shrink: 0; margin: 0;
  border: 1.5px solid #c3c8d6; background: #fff; border-radius: 6px; display: inline-grid; place-content: center; cursor: pointer;
  transition: background .15s, border-color .15s; vertical-align: -3px;
}
input[type=radio] { border-radius: 50%; }
input[type=radio]::after { content: ''; width: 8px; height: 8px; border-radius: 50%; background: #fff; opacity: 0; }
input[type=checkbox]:checked {
  background: var(--blue) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='10' viewBox='0 0 12 10'%3E%3Cpath d='M1.5 5.2l3 3 6-6.4' fill='none' stroke='%23fff' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 11px 9px no-repeat;
  border-color: var(--blue);
}
input[type=radio]:checked { background: var(--blue); border-color: var(--blue); }
input[type=radio]:checked::after { opacity: 1; }
input[type=checkbox]:focus-visible, input[type=radio]:focus-visible { outline: 3px solid #7e9cff; outline-offset: 2px; }

/* primary submit inside a form = dark pill, like the platform */
form .btn.grad, form button.btn:not(.ghost):not(.glass):not(.danger):not(.ok):not(.soft):not(.sm)[type=submit] { background: var(--ink); }
form .btn.grad:hover, form button.btn:not(.ghost):not(.glass):not(.danger):not(.ok):not(.soft):not(.sm)[type=submit]:hover { background: #2b2b45; }

/* ---------- shared card look ---------- */
.auth-card, .modal-card, .admin-page .panel, .account-page .panel {
  border-radius: 28px; border-color: var(--line); box-shadow: var(--f-card-shadow);
}

/* ---------- login / register / account ---------- */
.auth-card { width: min(520px, 100%); padding: 35px; margin: 56px auto; }
.auth-card::before {
  content: 'Arab Arena · Mecha AI'; display: block; width: max-content; direction: ltr;
  padding: 6px 14px 6px 28px; margin-bottom: 18px; border: 1px solid var(--line); border-radius: 30px;
  font-family: var(--fl); font-size: 11.5px; line-height: 1.6; color: var(--ink);
  background: #fff radial-gradient(circle, var(--blue) 3.5px, transparent 4px) no-repeat left 8px center / 12px 12px;
}
.auth-card h1 { font-size: 30px; font-weight: 600; letter-spacing: -.02em; line-height: 1.25; margin-bottom: 8px; }
.auth-card p.sub { font-size: 15px; margin-bottom: 26px; }
.auth-card form { gap: 18px; }
.auth-card form > label[style] { font-size: 13.5px; font-weight: 500 !important; color: var(--muted); align-items: flex-start !important; line-height: 1.7; }
.auth-card form > label[style] input { margin-top: 3px; }
.auth-card .btn { min-height: 52px; font-size: 15px; margin-top: 6px; background: var(--ink); }
.auth-card .btn:hover { background: #2b2b45; }
.auth-card .alt { font-size: 14px; }
.err-box { border-radius: 14px; font-size: 13.5px; }

/* ---------- partnership modal ---------- */
.modal-card { padding: 35px; }
.modal-head h3 { font-size: 28px; font-weight: 600; letter-spacing: -.02em; }
.modal-head .badge { font-size: 11.5px; }
.form-grid { gap: 18px 18px; }
.form-grid .btn { min-height: 52px; margin-top: 4px; }

/* ---------- admin: forms that enter data ---------- */
.admin-page .panel { padding: 30px; }
.admin-page .panel h3 { font-size: 16px; font-weight: 600; margin-bottom: 20px; justify-content: flex-start; gap: 12px; }
.admin-page .panel h3 > .ms:first-child {
  width: 30px; height: 30px; border-radius: 9px; display: inline-grid; place-items: center; font-size: 18px;
  background: var(--tint); border: 1px solid #e2e8fa; color: var(--blue); vertical-align: middle;
}
.admin-page .panel h3 > a { margin-inline-start: auto; font-size: 13px; font-weight: 500; }
.admin-page .fgrid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px 20px; margin-bottom: 20px; }
.admin-page .prov .fgrid, .admin-page .prov-grid .fgrid { grid-template-columns: 1fr; }
@media (max-width: 700px) { .admin-page .fgrid { grid-template-columns: 1fr; } }
.admin-page .panel form > label, .admin-page form.panel > label { margin-bottom: 18px; }
.admin-page .adm-h { font-size: 30px; font-weight: 600; letter-spacing: -.02em; }
.admin-page .row { gap: 10px; margin-top: 6px; }
/* checkbox groups → soft pill toggles */
.admin-page .caps-row { background: #fff; border: 1px solid var(--line); border-radius: 18px; padding: 14px 16px; gap: 8px; margin-bottom: 20px; }
.admin-page .caps-row > span { font-size: 13px; font-weight: 600; color: var(--f-label); margin-inline-end: 6px; }
.admin-page .caps-row .ck, .admin-page .row .ck {
  padding: 7px 14px 7px 12px; border: 1px solid var(--line); border-radius: 99px; background: var(--f-bg);
  font-size: 13.5px; font-weight: 500; color: var(--ink); transition: .15s;
}
.admin-page .caps-row .ck:hover, .admin-page .row .ck:hover { border-color: var(--f-line-h); }
.admin-page .caps-row .ck:has(input:checked), .admin-page .row .ck:has(input:checked) { background: var(--tint); border-color: #c9d4f8; color: var(--blue); }
.admin-page .pre-box { border-radius: 18px; padding: 18px; gap: 18px; background: #faf8ff; border: 1px dashed #d9d0ff; margin-bottom: 20px; }
.admin-page .pre-box .ck { font-weight: 500; color: var(--ink); line-height: 1.7; align-items: flex-start !important; }
.admin-page .prov { gap: 16px; }
.admin-page .prov-head { gap: 10px; padding-bottom: 14px; border-bottom: 1px solid #eef0f6; margin-bottom: 2px; }
.admin-page .prov-head .chip { font-size: 11.5px; }
.admin-page .inline-name { background: transparent; border-color: transparent; min-height: 40px; font-size: 16px; font-weight: 600; padding: 6px 10px; }
.admin-page .inline-name:hover { border-color: var(--f-line); background: var(--f-bg); }
.admin-page .filters { gap: 10px; }
.admin-page form.inline select { min-height: 40px; padding-block: 6px; font-size: 13.5px; }
.admin-page .dl { gap: 12px 18px; }
.admin-page .dl dt { font-size: 13px; }
.admin-page .kpi { border-radius: 22px; padding: 20px; box-shadow: var(--f-card-shadow); }
.admin-page .adm-side { border-radius: 26px; box-shadow: var(--f-card-shadow); }
.admin-page .adm-alert { border-radius: 22px; }
.admin-page .t th { background: #fbfcfe; }
.admin-page .panel > .btn, .admin-page form.panel > .btn { min-height: 50px; padding-inline: 26px; }

/* ---------- application flow (typeform): align the few boxed fields ---------- */
.tf-input.area { border-color: var(--f-line); border-radius: 18px; background: var(--f-bg) !important; }
.tf-input.area:focus { border-color: var(--blue); box-shadow: 0 0 0 4px #3563e914 !important; background: #fff !important; }
.choice { border-radius: 14px; background: var(--f-bg); border-color: var(--f-line); }
.consent { background: var(--f-bg); border-color: var(--f-line); }

/* ---------- phones ---------- */
@media (max-width: 720px) {
  .auth-card { padding: 26px 20px; margin: 24px auto; border-radius: 24px; }
  .auth-card h1 { font-size: 26px; }
  .modal-card { padding: 26px 20px; border-radius: 24px; }
  .modal-head h3 { font-size: 23px; }
  .admin-page .panel { padding: 20px; border-radius: 22px; }
  .admin-page .adm-h { font-size: 24px; }
  input:where(:not([type=checkbox]):not([type=radio]):not([type=range]):not([type=file]):not(.tf-input):not(.hp)), select, textarea:where(:not(.tf-input):not(#prompt)) { font-size: 16px; }
}
.admin-page .prov > label { margin-bottom: 0; }

/* =========================================================================
   Partnership page (/partners) — a real page, not a popup
   ========================================================================= */
.partner-page .fab-partner { display: none; }
.pp { padding: 56px 0 40px; }
.pp-grid { display: grid; grid-template-columns: .85fr 1.15fr; gap: 56px; align-items: start; }
.pp-intro { position: sticky; top: 120px; }
.pp-intro .badge, .pp-head .badge { background: #fff; font-size: 12px; }
.pp-intro h1 { font-size: clamp(34px, 3.8vw, 50px); font-weight: 700; line-height: 1.25; letter-spacing: -.02em; margin: 18px 0 14px; }
.pp-intro > p { font-size: 17px; line-height: 1.9; }
.pp-intro .checks { margin-top: 26px; }
.pp-mail { display: inline-flex; align-items: center; gap: 8px; margin-top: 26px; color: var(--blue); font-weight: 600; font-family: var(--fl); direction: ltr; }
.pp-form-wrap { min-width: 0; }
.pp-form, .pp-done { background: #fff; border: 1px solid var(--line); border-radius: 28px; padding: 35px; box-shadow: var(--f-card-shadow); }
.pp-head h2 { font-size: 30px; font-weight: 600; letter-spacing: -.02em; margin: 16px 0 8px; }
.pp-head p { font-size: 15px; margin-bottom: 8px; }
.pp-form fieldset { border: 0; padding: 0; margin: 30px 0 0; min-width: 0; }
.pp-form legend { display: flex; align-items: center; gap: 12px; font-size: 15px; font-weight: 600; color: var(--ink); margin-bottom: 18px; padding: 0; }
.pp-form legend span { width: 30px; height: 30px; border-radius: 9px; display: inline-grid; place-items: center; background: var(--tint); border: 1px solid #e2e8fa; color: var(--blue); font-family: var(--fl); font-size: 11px; font-weight: 600; }
.pp-fields { display: grid; grid-template-columns: 1fr 1fr; gap: 18px 18px; }
.pp-fields .full, .pp-form fieldset > label.full { grid-column: 1 / -1; }
.pp-types { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.pp-type { position: relative; display: grid; grid-template-columns: 38px 1fr; grid-template-rows: auto auto; column-gap: 12px; align-items: center;
  padding: 14px 16px; border: 1px solid var(--f-line); border-radius: 16px; background: var(--f-bg); cursor: pointer; transition: .15s; }
.pp-type:hover { border-color: var(--f-line-h); }
.pp-type input { position: absolute; opacity: 0; pointer-events: none; }
.pp-type .ms { grid-row: 1 / 3; width: 38px; height: 38px; border-radius: 12px; display: grid; place-items: center; background: #fff; border: 1px solid var(--line); color: var(--blue); font-size: 20px; }
.pp-type b { font-size: 14.5px; font-weight: 600; color: var(--ink); line-height: 1.4; }
.pp-type small { font-size: 12.5px; color: var(--muted); font-weight: 400; line-height: 1.5; }
.pp-type:has(input:checked) { background: var(--tint); border-color: var(--blue); box-shadow: inset 0 0 0 1px var(--blue); }
.pp-type:has(input:checked) .ms { background: var(--blue); border-color: var(--blue); color: #fff; }
.pp-type:has(input:focus-visible) { outline: 3px solid #7e9cff; outline-offset: 2px; }
.pp-form .btn.full { width: 100%; margin-top: 30px; min-height: 54px; font-size: 16px; }
.pp-note { text-align: center; font-size: 13px; margin-top: 14px; }
.pp-note a { color: var(--blue); }
.pp-err { margin-top: 18px; padding: 11px 14px; border-radius: 12px; background: var(--red-t); border: 1px solid #f6cfdc; color: #a61e4d; font-size: 14px; font-weight: 500; }
.pp-done { text-align: center; padding: 56px 35px; }
.pp-done > .ms { font-size: 44px; width: 84px; height: 84px; border-radius: 50%; display: inline-grid; place-items: center; background: var(--green-t); color: var(--green); }
.pp-done h2 { font-size: 30px; margin: 16px 0 8px; }
.pp-done p { margin-bottom: 24px; }

@media (max-width: 1000px) {
  .pp-grid { grid-template-columns: 1fr; gap: 30px; }
  .pp-intro { position: static; }
}

/* phones: forms are the page itself — no floating card */
@media (max-width: 720px) {
  .pp { padding: 28px 0 10px; }
  .pp-intro h1 { font-size: 30px; margin: 14px 0 10px; }
  .pp-intro > p { font-size: 15.5px; }
  .pp-intro .checks { margin-top: 16px; }
  .pp-intro .checks li { font-size: 14px; }
  .pp-mail { margin-top: 16px; }
  .pp-form, .pp-done { border: 0; border-radius: 0; box-shadow: none; padding: 26px 0 0; background: transparent; border-top: 1px solid var(--line); }
  .pp-head h2 { font-size: 24px; }
  .pp-fields { grid-template-columns: 1fr; gap: 16px; }
  .pp-types { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
  .pp-type { padding: 10px 10px; grid-template-columns: 32px 1fr; column-gap: 8px; border-radius: 14px; }
  .pp-type .ms { width: 32px; height: 32px; border-radius: 10px; font-size: 18px; grid-row: 1; }
  .pp-type b { font-size: 13px; }
  .pp-type small { display: none; }
  .pp-type { grid-template-rows: auto; min-height: 54px; }
  .pp-form fieldset { margin-top: 26px; }
  .partner-page .foot { margin-top: 20px; }

  /* login / register / account: full page, no card frame */
  .auth-card { border: 0 !important; box-shadow: none !important; background: transparent !important; border-radius: 0 !important; padding: 8px 0 0 !important; margin: 26px auto 10px !important; }
}
