/* git-forras.css — a code-test.html „Git-tároló" forrás-blokkja: mentett git-kapcsolat, új kapcsolat (URL + token / OAuth),
   tároló-kereső (combobox + listbox), ág/tag választó, kézi megadás. A style.css változóira és mező-stílusaira épül. */

/* Forrás-váltó: keskeny kijelzőn tördelődjön (4 gomb nem fér el egy sorban) */
#forrasSeg { flex-wrap: wrap; max-width: 100%; }
@media (max-width: 620px) {
  #forrasSeg { display: flex; border-radius: 18px; }
  #forrasSeg button { flex: 1 1 calc(50% - 4px); padding: 9px 10px; }
}

.gf input[type=url], .gf input[type=password] {
  width: 100%; padding: 13px 14px; border-radius: var(--r-sm); color: var(--ink); font-family: inherit; font-size: 15px;
  background: var(--paper); border: 1.5px solid var(--line); transition: border-color .15s, box-shadow .15s; min-width: 0; }
.gf input[type=url]:focus, .gf input[type=password]:focus { outline: none; border-color: var(--terra); box-shadow: 0 0 0 4px rgba(217,119,87,.15); background: #fff; }
.gf .gf-halk { color: var(--muted); font-size: 11px; font-weight: 400; text-transform: none; letter-spacing: 0; }
.gf .gf-hint { margin: 8px 0 0; font-size: 12.5px; }

/* mező + gomb egy sorban (kapcsolat-választó + ×, token + Kapcsolódás) */
.gf-sor { display: flex; gap: 8px; align-items: stretch; }
.gf-sor > select, .gf-sor > input { flex: 1 1 auto; min-width: 0; }
.gf-gomb { flex: none; margin: 0; padding: 0 18px; border-radius: var(--r-sm); font-family: inherit; font-size: 14px; font-weight: 600; cursor: pointer; }
.gf-gomb:disabled { opacity: .6; cursor: progress; }
.gf-x { flex: none; width: 46px; border-radius: var(--r-sm); border: 1.5px solid var(--line); background: #fff; color: var(--muted);
  font-size: 20px; line-height: 1; cursor: pointer; transition: color .12s, border-color .12s, background .12s; }
.gf-x:hover:not(:disabled), .gf-x:focus-visible { color: #a3382c; border-color: #e3a397; background: #fdf0ee; outline: none; }
.gf-x:disabled { opacity: .4; cursor: not-allowed; }

/* Új kapcsolat */
.gf-uj { margin-top: 4px; padding: 4px 16px 16px; border-radius: var(--r-sm); border: 1.5px dashed var(--line); background: color-mix(in srgb, var(--paper) 55%, #fff); }
.gf-kapcsolat + .gf-uj { margin-top: 12px; }
.gf-uj-fej { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; margin-top: 12px; font-size: 14px; }
.gf-oauth { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-top: 10px; }
.gf-oauth .gf-oauth-gomb { margin: 0; padding: 11px 20px; text-decoration: none; text-align: center; font-size: 14px; }
.gf-sugo { margin-top: 10px; font-size: 13px; color: var(--ink-2); }
.gf-sugo summary { cursor: pointer; color: var(--terra-d); font-weight: 600; width: fit-content; }
.gf-sugo summary:focus-visible { outline: 2px solid var(--terra); outline-offset: 2px; border-radius: 4px; }
.gf-sugo ul { margin: 8px 0 0; padding-left: 18px; line-height: 1.6; }
.gf-sugo code { font-family: 'Space Mono', monospace; font-size: 12px; background: var(--paper); border: 1px solid var(--line); border-radius: 5px; padding: 0 4px; }

/* Tároló-kereső */
.gf-combo { position: relative; }
.gf-lista { list-style: none; margin: 6px 0 0; padding: 4px; max-height: 300px; overflow-y: auto; border-radius: var(--r-sm);
  border: 1.5px solid var(--line); background: #fff; box-shadow: var(--shadow-s); }
.gf-opt { padding: 9px 11px; border-radius: 8px; cursor: pointer; border: 1.5px solid transparent; }
.gf-opt + .gf-opt { margin-top: 2px; }
.gf-opt:hover { background: var(--paper); }
.gf-opt[aria-selected="true"] { background: color-mix(in srgb, var(--terra) 12%, #fff); border-color: var(--terra); }
.gf-opt.valasztott .gf-opt-nev::before { content: "✓ "; color: var(--terra-d); }
.gf-opt-fej { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 10px; }
.gf-opt-nev { font-family: 'Space Mono', monospace; font-size: 13px; font-weight: 700; color: var(--ink); overflow-wrap: anywhere; }
.gf-opt-ido { margin-left: auto; font-family: 'Space Mono', monospace; font-size: 11px; color: var(--muted); white-space: nowrap; }
.gf-opt-leiras { margin-top: 3px; font-size: 12.5px; color: var(--muted); line-height: 1.45;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.gf-jel { font-size: 10.5px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; padding: 2px 7px; border-radius: 999px; }
.gf-jel.privat { background: #fbf0d6; color: #7a520c; border: 1px solid #ecd59f; }
.gf-jel.publikus { background: color-mix(in srgb, var(--green) 20%, #fff); color: #23704f; border: 1px solid color-mix(in srgb, var(--green) 50%, #fff); }
.gf-info { margin: 6px 0 0; min-height: 1.2em; font-size: 12.5px; color: var(--muted); }
.gf-ref-sor { margin-top: 2px; }

/* Hiba (aria-live) és a kézi mód kapcsolója */
.gf-hiba { margin: 12px 0 0; padding: 10px 14px; border-radius: var(--r-sm); background: #fdf0ee; border: 1px solid #efc2b9; color: #7a2a1e; font-size: 13px; line-height: 1.5; }
.gf-link { background: none; border: 0; padding: 0; color: var(--terra-d); font-family: inherit; font-size: 13px; font-weight: 600; cursor: pointer; text-decoration: underline; text-underline-offset: 3px; }
.gf-link:hover { color: var(--ink); }
.gf-link:focus-visible { outline: 2px solid var(--terra); outline-offset: 2px; border-radius: 4px; }
.gf-kezi-link { display: inline-block; margin-top: 14px; }
.gf-kezi { margin-top: 4px; }

@media (max-width: 620px) {
  .gf-sor { flex-wrap: wrap; }
  .gf-sor > .gf-gomb { flex: 1 1 100%; padding: 12px 18px; }
  .gf-kapcsolat .gf-sor { flex-wrap: nowrap; }
  .gf-opt-ido { margin-left: 0; }
  .gf-lista { max-height: 260px; }
}
