/* =========================================================================
   Bayi paneli — [gaia_bayi_paneli] (inc/partner-panel.php)
   Yalnız panel sayfasında yüklenir; renkler temanın değişkenlerinden.
   ========================================================================= */

.gaia-partner { display: grid; gap: 1.25rem; max-width: 760px; margin-inline: auto; }
.gaia-partner .gp-muted { color: var(--ink-soft); }
.gaia-partner .gp-small { font-size: .82rem; }
.gp-head p { margin: 0 0 .35rem; }
.gp-intro { max-width: 60ch; }

.gp-card {
	background: var(--porselen);
	border: 1px solid var(--line);
	border-radius: 4px;
	padding: clamp(1.1rem, 3vw, 1.75rem);
}
.gp-card h2 {
	display: flex; align-items: center; gap: .6rem;
	font-size: 1.15rem; margin: 0 0 1rem;
}
.gp-step {
	display: inline-grid; place-items: center;
	width: 1.6rem; height: 1.6rem; border-radius: 50%;
	background: var(--orman); color: var(--porselen);
	font-family: var(--f-cta); font-size: .78rem; font-weight: 600;
}

/* Bildirimler */
.gp-notice { padding: .9rem 1.1rem; border-radius: 4px; border: 1px solid; }
.gp-notice--ok { border-color: var(--orman); background: color-mix(in srgb, var(--orman) 10%, transparent); }
.gp-notice--error { border-color: #a33a2b; background: rgba(163, 58, 43, .08); color: #7d2a1f; }

/* Ürünler */
.gp-products { list-style: none; margin: 0; padding: 0; display: grid; gap: .5rem; }
.gp-product {
	display: grid; grid-template-columns: 52px 1fr auto; align-items: center; gap: .9rem;
	padding: .55rem .6rem; border: 1px solid transparent; border-radius: 4px;
	transition: border-color .25s var(--ease), background .25s var(--ease);
}
.gp-product.is-selected { border-color: var(--orman); background: #fff; }
.gaia-partner .gp-thumb { width: 52px; height: 52px; object-fit: cover; border-radius: 3px; background: var(--keten); }
.gp-product__info { display: grid; gap: .15rem; min-width: 0; }
.gp-product__name { font-weight: 500; overflow-wrap: anywhere; }
.gp-product__price { font-size: .9rem; color: var(--ink-soft); }

.gp-qty { display: inline-flex; align-items: center; border: 1px solid var(--line); border-radius: 3px; background: #fff; }
.gp-qty__btn {
	width: 44px; height: 44px; border: 0; background: none; cursor: pointer;
	font-size: 1.2rem; color: var(--ink);
}
.gp-qty__btn:hover { background: var(--keten); }
.gp-qty input {
	width: 2.6rem; height: 44px; border: 0; text-align: center; font: inherit;
	-moz-appearance: textfield; appearance: textfield; background: none;
}
.gp-qty input::-webkit-outer-spin-button,
.gp-qty input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }

/* Form alanları */
.gp-grid { display: grid; grid-template-columns: 1fr 1fr; gap: .9rem 1rem; }
.gp-grid label, .gp-note { display: grid; gap: .35rem; font-size: .88rem; font-weight: 500; }
.gp-wide { grid-column: 1 / -1; }
.gaia-partner input[type="text"], .gaia-partner input[type="tel"], .gaia-partner input[type="email"],
.gaia-partner select, .gaia-partner textarea {
	width: 100%; min-height: 44px; padding: .65rem .8rem;
	border: 1px solid var(--line); border-radius: 3px; background: #fff;
	font: inherit; font-weight: 400; color: var(--ink);
}
.gaia-partner input:focus, .gaia-partner select:focus, .gaia-partner textarea:focus {
	outline: 2px solid var(--orman); outline-offset: 1px; border-color: var(--orman);
}
.gp-grid small { font-weight: 400; }
.gp-note { margin-top: 1rem; }

/* Teslimat seçimi */
.gp-choice { display: grid; gap: .6rem; margin-bottom: 1rem; }
.gp-radio {
	display: grid; grid-template-columns: auto 1fr; gap: .75rem; align-items: start;
	padding: .85rem 1rem; border: 1px solid var(--line); border-radius: 4px; cursor: pointer; background: #fff;
}
.gp-radio:has(input:checked) { border-color: var(--orman); box-shadow: inset 0 0 0 1px var(--orman); }
.gp-radio input { margin-top: .25rem; accent-color: var(--orman); width: 18px; height: 18px; }
.gp-radio span { display: grid; gap: .2rem; }
.gp-radio.is-disabled { opacity: .55; cursor: not-allowed; }

/* Özet */
.gp-summary dl { margin: 0 0 1.1rem; display: grid; gap: .45rem; }
.gp-summary dl div { display: flex; justify-content: space-between; gap: 1rem; }
.gp-summary dt, .gp-summary dd { margin: 0; }
.gp-summary .gp-total { padding-top: .6rem; border-top: 1px solid var(--line); font-weight: 600; font-size: 1.1rem; }
.gp-submit { width: 100%; justify-content: center; min-height: 52px; }
.gp-submit:disabled { opacity: .6; cursor: progress; }

/* Son satışlar */
.gp-order-list { list-style: none; margin: 0; padding: 0; }
.gp-order { padding: .9rem 0; border-top: 1px solid var(--line); display: grid; gap: .5rem; }
.gp-order:first-child { border-top: 0; padding-top: 0; }
.gp-order__main, .gp-order__meta { display: flex; flex-wrap: wrap; gap: .35rem .8rem; align-items: baseline; justify-content: space-between; }
.gp-order__main { justify-content: flex-start; }
.gp-order__total { font-weight: 600; }
.gp-order__actions { display: flex; flex-wrap: wrap; gap: .5rem; }
.gp-order__actions form { margin: 0; }
.gp-btn-sm { padding: .6em 1.1em; font-size: .7rem; min-height: 40px; }
.gp-badge { font-size: .75rem; padding: .2rem .6rem; border-radius: 99px; background: var(--keten); color: var(--ink); }
.gp-badge--pending { background: #f1e3c4; color: #6b4f12; }
.gp-badge--processing, .gp-badge--completed { background: color-mix(in srgb, var(--orman) 18%, #fff); color: var(--orman); }
.gp-badge--failed, .gp-badge--cancelled { background: rgba(163, 58, 43, .12); color: #7d2a1f; }

/* Giriş kutusu */
.gp-login form p { display: grid; gap: .35rem; margin: 0 0 .9rem; }
.gp-login .login-remember label { display: flex; gap: .5rem; align-items: center; }
.gp-login input[type="password"] { width: 100%; min-height: 44px; padding: .65rem .8rem; border: 1px solid var(--line); border-radius: 3px; font: inherit; }
.gp-login input[type="submit"] { width: 100%; }

/* `hidden` özniteliği sınıf kurallarını (ör. .gp-grid{display:grid}) yensin. */
.gaia-partner [hidden] { display: none !important; }
.gaia-partner:not(.gp-js) .gp-js-only,
.gaia-partner:not(.gp-js) .gp-tabs,
.gaia-partner:not(.gp-js) .gp-stepper { display: none; }

/* Sekmeler */
.gp-tabs { display: flex; gap: .25rem; border-bottom: 1px solid var(--line); }
.gp-tab {
	appearance: none; background: none; border: 0; border-bottom: 2px solid transparent;
	padding: .75rem 1rem; margin-bottom: -1px; min-height: 44px; cursor: pointer;
	font-family: var(--f-cta); font-weight: 600; font-size: .78rem; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-soft);
}
.gp-tab.is-active { color: var(--orman); border-bottom-color: var(--orman); }

/* Adım göstergesi */
.gp-stepper { list-style: none; margin: 0 0 1rem; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: .4rem; counter-reset: none; }
.gp-stepper li {
	display: flex; flex-direction: column; align-items: center; gap: .35rem; cursor: pointer;
	font-size: .75rem; color: var(--ink-soft); text-align: center; position: relative;
}
.gp-stepper li::before { content: ""; position: absolute; top: .8rem; left: -50%; width: 100%; height: 1px; background: var(--line); z-index: 0; }
.gp-stepper li:first-child::before { display: none; }
.gp-stepper li span {
	position: relative; z-index: 1; width: 1.6rem; height: 1.6rem; border-radius: 50%; display: grid; place-items: center;
	border: 1px solid var(--line); background: var(--porselen); font-family: var(--f-cta); font-weight: 600; font-size: .75rem;
}
.gp-stepper li.is-current { color: var(--ink); font-weight: 600; }
.gp-stepper li.is-current span { background: var(--orman); border-color: var(--orman); color: var(--porselen); }
.gp-stepper li.is-done span { background: color-mix(in srgb, var(--orman) 18%, #fff); border-color: var(--orman); color: var(--orman); }
.gp-stepper li.is-done::before, .gp-stepper li.is-current::before { background: var(--orman); }

/* Adımlar açıkken kart başlığındaki numara tekrar etmesin */
.gp-js [data-gp-step] > h2 .gp-step { display: none; }

/* Alt gezinti: Geri · toplam · İleri — mobilde ekranın altına yapışır */
.gp-nav {
	position: sticky; bottom: 0; z-index: 5;
	display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: .75rem;
	padding: .75rem 0 calc(.75rem + env(safe-area-inset-bottom));
	background: linear-gradient(to bottom, transparent, var(--porselen) 30%);
}
.gp-nav.is-last { position: static; background: none; }
.gp-nav [data-gp-prev][hidden] + .gp-nav__total { grid-column: 1 / 3; }
.gp-nav__total { text-align: center; font-size: .88rem; font-weight: 600; }
.gp-nav .btn { min-height: 48px; justify-content: center; }
.gp-step-error { margin: .25rem 0 0; padding: .7rem 1rem; border-radius: 4px; background: rgba(163, 58, 43, .08); color: #7d2a1f; border: 1px solid #a33a2b; }

/* Onay özeti */
.gp-review { display: grid; gap: .9rem; margin-bottom: 1.1rem; }
.gp-review__block { padding-bottom: .9rem; border-bottom: 1px solid var(--line); }
.gp-review__block h3 { display: flex; justify-content: space-between; align-items: baseline; margin: 0 0 .4rem; font-size: .8rem; letter-spacing: .1em; text-transform: uppercase; font-family: var(--f-cta); color: var(--ink-soft); }
.gp-review__block p { margin: 0; }
.gp-review__items { list-style: none; margin: 0; padding: 0; display: grid; gap: .25rem; }
.gp-review__items li { display: flex; justify-content: space-between; gap: 1rem; }
.gp-link { background: none; border: 0; padding: .25rem 0; cursor: pointer; color: var(--orman); text-decoration: underline; font: inherit; font-size: .8rem; text-transform: none; letter-spacing: 0; }

/* Kayıtlı müşteri seçimi */
.gp-pick { margin-bottom: 1rem; }
.gp-pick__label { display: block; font-size: .88rem; font-weight: 500; margin-bottom: .35rem; }
.gp-pick__list { list-style: none; margin: 0; padding: 0; display: grid; gap: .4rem; }
.gp-pick__item {
	width: 100%; text-align: left; display: grid; gap: .1rem; cursor: pointer; min-height: 48px;
	padding: .6rem .8rem; border: 1px solid var(--line); border-radius: 4px; background: #fff; font: inherit; color: var(--ink);
}
.gp-pick__item:hover, .gp-pick__item:focus-visible { border-color: var(--orman); }
.gp-pick__item span { font-size: .8rem; color: var(--ink-soft); }
.gp-pick__chosen { margin: .6rem 0 0; padding: .6rem .8rem; border-radius: 4px; background: color-mix(in srgb, var(--orman) 10%, #fff); }
.gp-pick__or { display: flex; align-items: center; gap: .75rem; margin: 1rem 0 0; font-size: .78rem; color: var(--ink-soft); }
.gp-pick__or::before, .gp-pick__or::after { content: ""; flex: 1; height: 1px; background: var(--line); }

/* Sipariş detayı */
.gp-order__details summary { cursor: pointer; font-size: .82rem; color: var(--orman); text-decoration: underline; width: max-content; min-height: 32px; display: flex; align-items: center; }
.gp-order__details[open] { padding: .5rem .75rem; background: #fff; border: 1px solid var(--line); border-radius: 4px; }
.gp-order__details p { margin: .5rem 0 0; }

/* Arama */
.gp-search { display: block; margin-bottom: .9rem; }
.gaia-partner .gp-search input {
	width: 100%; min-height: 44px; padding: .65rem .8rem .65rem 2.4rem;
	border: 1px solid var(--line); border-radius: 3px; font: inherit; color: var(--ink);
	background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none' stroke='%236f6f68' stroke-width='2'%3E%3Ccircle cx='7' cy='7' r='5'/%3E%3Cpath d='m11 11 4 4'/%3E%3C/svg%3E") no-repeat .8rem center;
}
.gp-product__code { font-size: .78rem; color: var(--ink-soft); font-family: ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: .02em; }
.gp-product[hidden] { display: none; }
.gp-search-empty { margin: 0 0 .5rem; }

/* Bayi başvurusu */
.gp-apply summary { cursor: pointer; list-style: none; display: grid; gap: .25rem; }
.gp-apply summary::-webkit-details-marker { display: none; }
.gp-apply summary h2 { margin: 0; }
.gp-apply summary h2::after { content: "+"; margin-left: auto; font-weight: 300; }
.gp-apply[open] summary h2::after { content: "−"; }
.gp-apply[open] summary { margin-bottom: 1.1rem; }
.gp-apply .gp-submit { margin-top: 1.1rem; }
.gp-check { grid-template-columns: auto 1fr !important; align-items: start; font-weight: 400 !important; }
.gp-check input { width: 18px; height: 18px; margin-top: .15rem; accent-color: var(--orman); }
.gp-check a { text-decoration: underline; }
.gp-hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

@media (max-width: 560px) {
	.gp-grid { grid-template-columns: 1fr; }
	.gp-product { grid-template-columns: 44px 1fr; }
	.gaia-partner .gp-thumb { width: 44px; height: 44px; }
	.gp-qty { grid-column: 1 / -1; justify-self: end; }
}
