﻿:root {
  font-family: "Segoe UI", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  --rail-width: 68px;
  --sidebar-width: 248px;
  --surface: #ffffff;
  --surface-accent: #f1f5f9;
  --line: rgba(229, 231, 235, 0.6);
  --text-main: #0f172a;
  --text-soft: #64748b;
  --accent: #2563eb;
  --accent-strong: #1e40af;
  --accent-soft: #3b82f6;
  --bg-orb-1: rgba(30, 64, 175, 0.14);
  --bg-orb-2: rgba(191, 219, 254, 0.72);
  --bg-orb-3: rgba(147, 197, 253, 0.52);
  --bg-base: #f7faff;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(circle at 50% 28%, var(--bg-orb-1), transparent 20%),
    radial-gradient(circle at 24% 18%, var(--bg-orb-2), transparent 26%),
    radial-gradient(circle at 78% 20%, var(--bg-orb-3), transparent 24%),
    radial-gradient(circle at 50% 72%, rgba(255, 255, 255, 0.38), transparent 32%),
    var(--bg-base);
  color: var(--text-main);
  overflow-x: hidden;
}

button,
input,
select {
  font: inherit;
  color: inherit;
}

.app-shell {
  min-height: 100vh;
}

.layout {
  display: grid;
  grid-template-columns: auto 1fr;
  min-height: 100vh;
}

.layout.layout-no-sidebar {
  grid-template-columns: 1fr;
}

.hub-layout-main {
  width: 100%;
}

.sidebar {
  position: sticky;
  top: 0;
  display: flex;
  flex-direction: column;
  width: var(--rail-width);
  height: 100vh;
  padding: 18px 10px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.8), rgba(255, 255, 255, 0.66)),
    linear-gradient(180deg, rgba(59, 130, 246, 0.04), rgba(30, 64, 175, 0.04));
  border-right: 1px solid var(--line);
  backdrop-filter: blur(20px);
  transition: width 0.22s cubic-bezier(0.4, 0, 0.2, 1);
  z-index: 10;
}

.sidebar.open {
  width: var(--sidebar-width);
  padding: 18px;
}



.sidebar:not(.open) .sidebar-header-new {
  justify-content: center;
}

.sidebar-close-btn {
  width: 44px;
  height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 8px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--surface);
  cursor: pointer;
  font-size: 1.4rem;
  color: var(--text-main);
  flex: 0 0 44px;
  transition: all 0.2s ease;
}

.sidebar-close-btn:hover {
  background: var(--surface-accent);
}

.sidebar:not(.open) .sidebar-close-btn {
  display: none;
}

.sidebar-new-chat {
  display: flex;
  align-items: center;
  gap: 12px;
  flex: 1;
  text-decoration: none;
  color: var(--text-main);
}

.sidebar-new-chat-text {
  font-size: 0.95rem;
  font-weight: 600;
}

.sidebar-new-chat-icon {
  width: 44px;
  height: 44px;
  flex: 0 0 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--surface);
  font-size: 1.2rem;
}

.sidebar:not(.open) .sidebar-new-chat {
  justify-content: center;
  width: 48px;
  align-self: center;
}

.sidebar:not(.open) .sidebar-new-chat-text {
  display: none;
}

.sidebar:not(.open) .sidebar-footer {
  position: static;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  align-self: center;
}

.sidebar-footer {
  margin-top: auto;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.sidebar-profile-link,
.sidebar-footer-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  width: 100%;
  margin-top: auto;
  text-decoration: none;
  color: var(--text-main);
}

.sidebar-profile-link-text,
.sidebar-footer-link-text {
  font-size: 0.95rem;
  font-weight: 600;
  opacity: 0;
  transition: all 0.2s ease;
}

.sidebar.open .sidebar-profile-link-text,
.sidebar.open .sidebar-footer-link-text {
  opacity: 1;
}

.sidebar-profile-link.active .sidebar-profile-link-icon {
  border-color: var(--line);
  background: var(--surface);
  color: #14b8a6;
  box-shadow: none;
}

.sidebar:not(.open) .sidebar-profile-link-text,
.sidebar:not(.open) .sidebar-footer-link-text {
  display: none;
}

.sidebar:not(.open) .sidebar-profile-link,
.sidebar:not(.open) .sidebar-footer-link {
  justify-content: center;
  margin-top: 0;
}

.sidebar-profile-link-icon,
.sidebar-footer-link-icon {
  width: 44px;
  height: 44px;
  flex: 0 0 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--surface);
}

.sidebar-profile-link:hover .sidebar-profile-link-icon,
.sidebar-profile-link.active .sidebar-profile-link-icon {
  border-color: var(--line);
  background: var(--surface);
}

.sidebar-footer-link:hover .sidebar-footer-link-icon {
  border-color: var(--line);
  background: var(--surface);
}

.sidebar-profile-link-icon-svg {
  width: 20px;
  height: 20px;
  display: block;
}

.sidebar-footer-link-logo {
  width: 20px;
  height: 20px;
  display: block;
  object-fit: contain;
}

.sidebar-footer-link-icon-svg {
  width: 20px;
  height: 20px;
  display: block;
  color: var(--text-main);
}

.main {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  padding: 42px 24px 24px;
  max-width: 780px;
  margin: 0 auto;
  width: 100%;
}

.chat-zone {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.welcome-screen {
  text-align: center;
  margin: 0;
  padding: 20px 0 0;
  max-width: 640px;
  align-self: center;
}

.welcome-title {
  font-size: clamp(2.2rem, 5.2vw, 3.8rem);
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.2;
  margin: 0 0 14px;
  background: linear-gradient(135deg, var(--accent-strong) 40%, var(--accent-soft));
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  padding-bottom: 4px;
}

.welcome-subtitle {
  color: var(--text-main);
  font-size: 0.98rem;
  line-height: 1.45;
  margin: 0;
}

.chat-history {
  display: none;
  flex-direction: column;
  gap: 24px;
  margin: 36px 0 0;
}

.chat-empty-state {
  width: min(100%, 640px);
  margin: 0 auto;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.56);
  text-align: center;
  color: var(--text-soft);
}

.chat-empty-eyebrow {
  display: inline-block;
  margin-bottom: 10px;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
}

.chat-empty-title {
  margin: 0 0 8px;
  font-size: 1.15rem;
  color: var(--text-main);
}

.chat-empty-hint {
  margin: 0;
  font-size: 0.92rem;
}

.chat-message {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.chat-message-user {
  justify-content: flex-end;
  align-items: flex-end;
}

.chat-message-assistant {
  justify-content: flex-start;
  align-items: flex-start;
}

.chat-message-bubble {
  max-width: min(680px, 100%);
  padding: 14px 18px;
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.75);
  border: 1px solid var(--line);
  line-height: 1.6;
}

.chat-message-user .chat-message-bubble {
  background: #0f172a;
  color: #ffffff;
  border-color: #0f172a;
}

.chat-input-container {
  position: relative;
  background: rgba(255, 255, 255, 0.75);
  backdrop-filter: blur(24px);
  border: 1px solid var(--line);
  border-radius: 32px;
  padding: 8px 10px 8px 24px;
  display: flex;
  align-items: center;
  box-shadow:
    0 18px 48px rgba(15, 23, 42, 0.05),
    0 0 0 1px rgba(255, 255, 255, 0.45) inset;
  margin: 36px auto 0;
  width: min(100%, 640px);
  min-width: 0;
}

.chat-prompt-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 16px auto 0;
  width: min(100%, 640px);
  justify-content: center;
}

.chat-prompt-chips-inline {
  width: 100%;
  justify-content: flex-start;
  margin-top: 4px;
}

.welcome-hub-tags {
  margin: 18px auto 0;
  width: min(100%, 720px);
  justify-content: center;
}

.chat-input-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  width: min(100%, 640px);
  margin: 12px auto 0;
}

.tone-switch {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.tone-switch-btn {
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.82);
  color: var(--text-soft);
  border-radius: 999px;
  padding: 7px 12px;
  cursor: pointer;
  font-size: 0.82rem;
  font-weight: 700;
}

.tone-switch-btn.active {
  background: var(--text-main);
  color: #ffffff;
  border-color: var(--text-main);
}

.chat-input-counter {
  color: var(--text-soft);
  font-size: 0.84rem;
  font-weight: 600;
}

.prompt-chip {
  border: 1px solid rgba(15, 23, 42, 0.12);
  background: rgba(255, 255, 255, 0.9);
  color: var(--text-main);
  padding: 10px 14px;
  border-radius: 999px;
  cursor: pointer;
  font-size: 0.95rem;
  transition: transform 0.18s ease, background 0.18s ease;
}

.prompt-chip:hover {
  background: rgba(255, 255, 255, 1);
  transform: translateY(-1px);
}

.chat-input,
.chat-textarea {
  border: none;
  background: transparent;
  flex: 1;
  outline: none;
  font-size: 1.05rem;
  padding: 12px 0;
  resize: none;
  min-height: 44px;
  line-height: 1.5;
}

.chat-textarea {
  width: 100%;
}

.chat-send-btn {
  background: var(--text-main);
  color: #fff;
  border: none;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  transition: background 0.2s;
}

.chat-send-btn:hover {
  background: var(--accent);
}

.profile-view {
  display: none;
  margin: 40px 0 auto;
}

.profile-view h2 {
  font-size: 1.8rem;
  font-weight: 600;
  margin: 0 0 6px;
}

.profile-view-subtitle {
  color: var(--text-soft);
  margin: 0 0 32px;
}

.settings-group {
  background: rgba(255, 255, 255, 0.6);
  border: 1px solid var(--line);
  border-radius: 24px;
  padding: 8px 24px;
  margin-bottom: 24px;
}

.settings-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 0;
  font-weight: 500;
}

.settings-item-stack {
  flex-direction: column;
  align-items: flex-start;
  gap: 6px;
}

.settings-label {
  color: var(--text-soft);
  font-size: 0.9rem;
}

.settings-value {
  color: var(--text-main);
  font-size: 1rem;
  font-weight: 600;
}

.settings-item:not(:last-child) {
  border-bottom: 1px solid var(--line);
}

  .minimal-btn-close {
    display: inline-block;
    color: var(--text-soft);
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 500;
    padding: 8px 0;
  }

  .minimal-btn-close:hover {
    color: var(--text-main);
}

.main.has-messages .welcome-screen {
  display: none;
}

.main.has-messages .welcome-prompt-chips {
  display: none;
}

.main.has-messages .chat-history {
  display: flex;
}

.footer {
  margin-top: 56px;
  padding: 24px 0 10px;
  text-align: center;
  color: var(--text-soft);
  font-size: 0.8rem;
  opacity: 0.8;
}

.hub-body {
  min-height: 100vh;
  padding: 0;
}

.hub-layout-main {
  min-height: 100vh;
  padding: 32px 24px;
}

.hub-shell {
  width: min(1320px, 100%);
  margin: 0 auto;
}

.hub-sections {
  display: flex;
  flex-direction: column;
  gap: 36px;
}

.hub-hero {
  text-align: center;
  max-width: 840px;
  margin: 0 auto 40px;
}

.hub-logo {
  width: 72px;
  height: 72px;
  margin-bottom: 18px;
}

.hub-eyebrow {
  margin: 0 0 8px;
  color: var(--accent-strong);
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.hub-title {
  margin: 0 0 14px;
  font-size: clamp(2.4rem, 5vw, 4.3rem);
  line-height: 1;
  letter-spacing: -0.04em;
  background: linear-gradient(135deg, #0c2f76 25%, var(--accent-soft));
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hub-subtitle {
  margin: 0;
  color: var(--text-soft);
  font-size: 1.12rem;
  line-height: 1.8;
}

.hub-brand-panel {
  width: 100%;
  padding: 22px 24px;
  margin: 0 auto 36px;
  border-radius: 28px;
  border: 1px solid rgba(15, 23, 42, 0.08);
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 24px 80px rgba(15, 23, 42, 0.08);
}

.hub-brand-panel-caption {
  margin: 0 0 16px;
  color: var(--text-main);
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.hub-brand-panel-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  align-items: stretch;
}

.hub-brand-panel-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 14px 12px;
  border-radius: 20px;
  text-decoration: none;
  color: var(--text-main);
  border: 1px solid rgba(15, 23, 42, 0.08);
  background: rgba(255, 255, 255, 0.88);
  transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
}

.hub-brand-panel-item:hover {
  transform: translateY(-2px);
  border-color: rgba(0, 71, 171, 0.22);
  box-shadow: 0 18px 40px rgba(15, 23, 42, 0.08);
}

.hub-brand-panel-logo {
  width: 44px;
  height: 44px;
  object-fit: contain;
}

.hub-brand-panel-title {
  display: block;
  margin: 0;
  font-size: 0.88rem;
  text-align: center;
  line-height: 1.4;
}

.hub-section {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.hub-section-title {
  margin: 0;
  font-size: 1.15rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--text-main);
}

.hub-section-description {
  margin: 0;
  color: var(--text-soft);
  font-size: 0.98rem;
  line-height: 1.6;
}

.hub-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 28px;
  width: 100%;
}

.hub-card {
  --hub-card-bg: rgba(255, 255, 255, 0.76);
  --hub-card-bg-secondary: rgba(255, 255, 255, 0.62);
  --hub-card-glow: rgba(148, 163, 184, 0.1);
  --hub-card-border: rgba(229, 231, 235, 0.9);
  --hub-card-badge-bg: rgba(255, 255, 255, 0.8);
  --hub-card-badge-border: rgba(229, 231, 235, 0.9);
  display: flex;
  flex-direction: column;
  min-height: 360px;
  padding: 30px;
  border: 1px solid var(--hub-card-border);
  border-radius: 28px;
  background:
    radial-gradient(circle at top left, var(--hub-card-glow), transparent 44%),
    linear-gradient(160deg, var(--hub-card-bg), var(--hub-card-bg-secondary));
  backdrop-filter: blur(24px);
  text-decoration: none;
  color: var(--text-main);
  overflow: hidden;
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.hub-card:hover {
  transform: translateY(-3px);
  border-color: rgba(37, 99, 235, 0.2);
  box-shadow: 0 18px 40px rgba(15, 23, 42, 0.05);
}

.hub-card-muted {
  background: rgba(255, 255, 255, 0.52);
}

.hub-card-muted .hub-card-cta {
  color: var(--text-soft);
  font-weight: 600;
}

.hub-card-hero-image {
  display: block;
  width: calc(100% + 56px);
  max-width: none;
  height: 258px;
  margin: -28px -28px 22px;
  object-fit: cover;
  object-position: center;
  border-radius: 28px 28px 26px 26px;
  box-shadow: inset 0 -14px 24px rgba(255, 255, 255, 0.18);
}

.hub-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 28px;
}

.hub-card-head-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-left: auto;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.hub-card-logo {
  width: 48px;
  height: 48px;
  object-fit: contain;
  flex-shrink: 0;
}

.hub-card-badge {
  padding: 8px 12px;
  border-radius: 999px;
  background: var(--hub-card-badge-bg);
  border: 1px solid var(--hub-card-badge-border);
  color: var(--text-soft);
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.hub-card-badge-lumy {
  background: rgba(30, 41, 59, 0.94);
  border-color: rgba(30, 64, 175, 0.28);
  color: #eff6ff;
  text-transform: none;
  letter-spacing: 0.02em;
}

.hub-card-languages {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  white-space: nowrap;
}

.hub-card-language-link {
  color: rgba(15, 23, 42, 0.58);
  text-decoration: none;
  transition: color 140ms ease;
}

.hub-card-language-link-globe {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

.hub-card-language-icon {
  width: 0.92rem;
  height: 0.92rem;
  display: block;
}

.hub-card-language-link:hover,
.hub-card-language-link:focus-visible,
.hub-card-language-link.is-active {
  color: #0f172a;
}

.hub-card-language-separator {
  color: rgba(15, 23, 42, 0.34);
}

.hub-card h2 {
  margin: 0 0 12px;
  font-size: 1.45rem;
  letter-spacing: -0.02em;
}

.hub-card p {
  margin: 0;
  color: var(--text-soft);
  line-height: 1.7;
}

.hub-card-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 18px;
}

.hub-card-tag {
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.6);
  color: var(--text-soft);
  font-size: 0.76rem;
  font-weight: 700;
}

/* Ensure visible separation between tag pills even if gap isn't applied */
.hub-card-tag {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.hub-card-tag + .hub-card-tag {
  margin-left: 0;
}

.hub-card-cta {
  margin-top: auto;
  padding-top: 32px;
  font-weight: 700;
}

.hub-card-hajdukovac {
  background:
    radial-gradient(circle at 18% 18%, rgba(227, 30, 36, 0.12), transparent 22%),
    radial-gradient(circle at 82% 16%, rgba(0, 71, 171, 0.14), transparent 24%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.82), rgba(255, 255, 255, 0.72)),
    linear-gradient(160deg, var(--hub-card-bg), var(--hub-card-bg-secondary));
}

.hub-card-hajdukovac .hub-card-head {
  margin-bottom: 22px;
}

.hub-card-hajdukovac .hub-card-logo {
  width: 56px;
  height: 56px;
}

.hub-card-hajdukovac .hub-card-badge {
  color: var(--accent-strong);
  border-color: rgba(227, 30, 36, 0.24);
  background: rgba(255, 255, 255, 0.9);
}

.hub-card-hajdukovac h2 {
  background: linear-gradient(135deg, #e31e24 8%, #0047ab 58%, #5b8def);
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  font-size: 1.7rem;
  line-height: 1.12;
  margin-bottom: 14px;
}

.hub-card-hajdukovac p {
  color: #334155;
  line-height: 1.65;
}

.hub-card-hajdukovac .hub-card-tags {
  gap: 10px;
  margin-top: 20px;
}

.hub-card-hajdukovac .hub-card-tag {
  background: rgba(255, 255, 255, 0.88);
  border-color: rgba(0, 71, 171, 0.14);
  color: #0f172a;
  font-weight: 700;
}

.hub-card-hajdukovac .hub-card-cta {
  color: #0047ab;
  font-weight: 800;
}

@media (max-width: 720px) {
  .layout {
    grid-template-columns: 1fr;
  }

  .sidebar {
    position: fixed;
    left: 0;
    height: 100vh;
    box-shadow: 10px 0 30px rgba(0, 0, 0, 0.02);
  }

  .main {
    padding-left: calc(var(--rail-width) + 16px);
  }

  .hub-layout-main {
    padding-left: calc(var(--rail-width) + 16px);
  }

  .layout.layout-no-sidebar .hub-layout-main {
    padding: 24px 16px;
  }

  .chat-zone {
    justify-content: center;
  }

  .welcome-title {
    font-size: 2rem;
  }

  .welcome-screen {
    padding-top: 8px;
  }

  .chat-input-container {
    width: 100%;
  }

  .hub-card {
    min-height: auto;
    padding: 24px;
  }

  .hub-card-hero-image {
    width: calc(100% + 48px);
    height: 220px;
    margin: -24px -24px 20px;
    border-radius: 24px 24px 22px 22px;
  }

  .hub-card-head {
    gap: 16px;
    margin-bottom: 22px;
    align-items: flex-start;
  }

  .hub-card-head-actions {
    gap: 10px;
    flex-wrap: wrap;
    justify-content: flex-end;
  }

  .hub-card-badge {
    font-size: 0.72rem;
  }

  .hub-card-languages {
    font-size: 0.68rem;
    gap: 6px;
  }

  .hub-card h2 {
    font-size: 1.32rem;
  }

  .hub-card-tags {
    gap: 6px;
  }

  .hub-card-tag {
    padding: 5px 9px;
    font-size: 0.72rem;
  }

  .hub-grid {
    grid-template-columns: 1fr;
  }

  .hub-brand-panel {
    padding: 16px 14px;
  }

  .hub-brand-panel-grid {
    gap: 10px;
    grid-template-columns: repeat(auto-fit, minmax(110px, 1fr));
  }

  .hub-brand-panel-item {
    padding: 12px 10px;
  }
}
