/* ============================================================
   WebDev — Full-Stack Web Development
   ============================================================ */

/* Sub-nav — pill style */
.sub-nav {
  display: flex;
  align-items: center;
  gap: 4px;
  flex: 1;
  padding: 5px;
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 14px;
}
.sub-nav-link {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: var(--font-primary);
  font-size: 13px;
  font-weight: 600;
  color: rgba(255,255,255,0.5);
  padding: 8px 10px;
  border-radius: 10px;
  border: none;
  text-decoration: none;
  transition: color 0.2s ease, background 0.2s ease;
  white-space: nowrap;
  line-height: 1;
}
.sub-nav-link:hover { color: rgba(255,255,255,0.85); background: rgba(255,255,255,0.07); }
.sub-nav-link.active { background: #ffffff; color: #0d0d1a; font-weight: 700; }
.sub-nav-icon { display: flex; align-items: center; justify-content: center; width: 15px; height: 15px; flex-shrink: 0; }
.back-link {
  font-family: var(--font-primary);
  font-size: 13px;
  font-weight: 500;
  color: var(--white-50);
  text-decoration: none;
  transition: var(--transition);
  white-space: nowrap;
}
.back-link:hover { color: var(--white-80); }

/* ============================================================
   BUILD CARD — code editor visual
   ============================================================ */
.wd-editor-visual {
  background: #0d1117;
  border-color: rgba(255,255,255,0.08) !important;
}
.code-editor {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  font-family: 'Courier New', Courier, monospace;
}
.editor-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  background: rgba(255,255,255,0.04);
  border-bottom: 1px solid rgba(255,255,255,0.06);
  flex-shrink: 0;
}
.editor-dots { display: flex; gap: 6px; }
.ed-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}
.ed-dot--r { background: #ff5f57; }
.ed-dot--y { background: #febc2e; }
.ed-dot--g { background: #28c840; }
.editor-filename {
  font-family: var(--font-body);
  font-size: 11px;
  color: rgba(255,255,255,0.4);
  flex: 1;
  text-align: center;
}
.editor-lang {
  font-family: var(--font-primary);
  font-size: 10px;
  font-weight: 700;
  color: var(--cyan);
  letter-spacing: 0.08em;
}
.editor-body {
  flex: 1;
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  overflow: hidden;
}
.cl {
  display: flex;
  align-items: baseline;
  gap: 0;
  font-size: 12.5px;
  line-height: 1.7;
  opacity: 0;
  animation: line-in 0.25s ease forwards;
  white-space: nowrap;
}
.cl-1  { animation-delay: 0.3s; }
.cl-2  { animation-delay: 0.55s; }
.cl-3  { animation-delay: 0.8s; }
.cl-4  { animation-delay: 1.05s; }
.cl-5  { animation-delay: 1.3s; }
.cl-6  { animation-delay: 1.55s; }
.cl-7  { animation-delay: 1.8s; }
.cl-8  { animation-delay: 2.05s; }
.cl-9  { animation-delay: 2.3s; }
.cl-10 { animation-delay: 2.55s; }
.cl-11 { animation-delay: 2.8s; }
@keyframes line-in {
  from { opacity: 0; transform: translateX(-6px); }
  to   { opacity: 1; transform: translateX(0); }
}
.ln {
  display: inline-block;
  min-width: 22px;
  margin-right: 14px;
  font-size: 11px;
  color: rgba(255,255,255,0.18);
  user-select: none;
  text-align: right;
  flex-shrink: 0;
}
.sy-tag  { color: #7ec8e3; }
.sy-attr { color: #c792ea; }
.sy-str  { color: #c3e88d; }
.sy-key  { color: var(--magenta); }
.sy-fn   { color: var(--cyan); }
.sy-var  { color: #eeffff; }
.sy-txt  { color: rgba(255,255,255,0.75); }
.sy-com  { color: rgba(255,255,255,0.25); font-style: italic; }
.code-cursor {
  display: inline-block;
  width: 2px;
  height: 14px;
  background: var(--cyan);
  vertical-align: middle;
  margin-left: 2px;
  animation: cursor-blink 1s step-end infinite;
  animation-delay: 3s;
}
@keyframes cursor-blink {
  0%, 100% { opacity: 1; }
  50%       { opacity: 0; }
}

/* ============================================================
   REFERENCES — portfolio grid
   ============================================================ */
.wd-ref-sub {
  font-family: var(--font-body);
  font-size: 13px;
  color: var(--white-50);
  text-align: center;
  margin: 8px 0 40px;
}
.ref-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}
.ref-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  text-decoration: none;
  display: flex;
  flex-direction: column;
  transition: border-color 0.25s ease, transform 0.25s ease, box-shadow 0.25s ease;
}
.ref-card:hover {
  border-color: var(--border-glow);
  transform: translateY(-4px);
  box-shadow: 0 12px 40px rgba(0,173,241,0.1);
}
.ref-card--featured {
  grid-column: span 2;
  background: linear-gradient(135deg, var(--surface) 0%, rgba(0,173,241,0.06) 100%);
  border-color: var(--border-glow);
}
/* Browser bar on each card */
.ref-browser-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  background: rgba(255,255,255,0.03);
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}
.ref-dots { display: flex; gap: 4px; }
.ref-dots span {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: rgba(255,255,255,0.15);
}
.ref-url {
  font-family: var(--font-body);
  font-size: 10px;
  color: var(--white-30);
  flex: 1;
  text-align: center;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
/* Card body */
.ref-body {
  flex: 1;
  padding: 16px 18px 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.ref-live-badge {
  display: inline-block;
  font-family: var(--font-primary);
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.1em;
  color: var(--cyan);
  background: rgba(0,173,241,0.1);
  border: 1px solid rgba(0,173,241,0.2);
  border-radius: 4px;
  padding: 2px 7px;
  align-self: flex-start;
}
.ref-title {
  font-family: var(--font-primary);
  font-size: 16px;
  font-weight: 700;
  color: var(--white);
  margin: 0;
}
.ref-card--featured .ref-title { font-size: 20px; }
.ref-desc {
  font-family: var(--font-body);
  font-size: 12.5px;
  color: var(--white-50);
  line-height: 1.55;
  margin: 0;
}
.ref-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: auto;
  padding-top: 6px;
}
.ref-tags span {
  font-family: var(--font-primary);
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 0.06em;
  color: var(--white-30);
  background: rgba(255,255,255,0.05);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 2px 7px;
}
/* Visit footer — вистинско копче за да е јасно дека е кликабилно */
.ref-cta {
  margin: 4px 18px 16px;
  padding: 12px 18px;
  border-radius: 999px;
  text-align: center;
  font-family: var(--font-primary);
  font-size: 12px;
  font-weight: 700;
  color: #fff;
  letter-spacing: 0.05em;
  background: linear-gradient(90deg, var(--cyan), #ed008c);
  box-shadow: 0 4px 14px rgba(0,173,241,0.25);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.ref-card:hover .ref-cta {
  color: #fff;
  transform: scale(1.03);
  box-shadow: 0 6px 22px rgba(237,0,140,0.35);
}

/* Screenshot реагира на hover — картичката се чувствува "жива" */
.ref-screenshot { transition: transform 0.3s ease; }
.ref-card:hover .ref-screenshot { transform: scale(1.03); }

/* "Your Project" CTA card */
.ref-card--cta {
  cursor: default;
  background: linear-gradient(135deg, var(--surface) 0%, rgba(237,0,140,0.06) 100%);
  border-color: rgba(237,0,140,0.2);
  align-items: center;
  justify-content: center;
  min-height: 200px;
}
.ref-card--cta:hover {
  border-color: rgba(237,0,140,0.4);
  box-shadow: 0 12px 40px rgba(237,0,140,0.08);
}
.ref-cta-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  padding: 24px;
  text-align: center;
}
.ref-cta-icon {
  font-size: 28px;
  color: var(--magenta);
}
.ref-cta-inner h3 {
  font-family: var(--font-primary);
  font-size: 18px;
  font-weight: 700;
  color: var(--white);
  margin: 0;
}
.ref-cta-inner p {
  font-family: var(--font-body);
  font-size: 13px;
  color: var(--white-50);
  margin: 0;
}

/* ============================================================
   AI CARD — chat mock (full-height feature visual)
   ============================================================ */
.wd-chat-visual {
  background: var(--surface);
  display: flex;
  align-items: stretch;
}
.wd-chat-visual .chat-mock {
  position: absolute;
  inset: 24px;
  border-radius: var(--radius-lg);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: var(--surface);
  border: 1px solid var(--border-glow);
  box-shadow: 0 0 30px rgba(0,173,241,0.08);
}
.chat-header {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border);
  background: var(--surface-2);
}
.chat-bot-icon { font-size: 22px; color: var(--cyan); }
.chat-bot-name { display: block; font-family: var(--font-primary); font-size: 13px; font-weight: 700; color: var(--white); }
.chat-bot-status { display: block; font-family: var(--font-body); font-size: 11px; color: var(--cyan); }
.chat-messages {
  flex: 1;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  overflow: hidden;
}
.chat-msg { max-width: 80%; }
.chat-msg p { font-family: var(--font-body); font-size: 13px; line-height: 1.5; padding: 10px 14px; border-radius: 12px; margin: 0; }
.chat-msg--bot p { background: var(--surface-2); color: var(--white-80); border-bottom-left-radius: 4px; }
.chat-msg--user { align-self: flex-end; }
.chat-msg--user p { background: linear-gradient(135deg,rgba(0,173,241,0.2),rgba(237,0,140,0.15)); color: var(--white); border-bottom-right-radius: 4px; border: 1px solid var(--border-glow); }
.chat-typing { display: flex; gap: 4px; align-items: center; padding: 4px 0; }
.chat-typing span { width: 6px; height: 6px; background: var(--white-50); border-radius: 50%; animation: typing-bounce 1.2s infinite; }
.chat-typing span:nth-child(2) { animation-delay: 0.2s; }
.chat-typing span:nth-child(3) { animation-delay: 0.4s; }
@keyframes typing-bounce { 0%,60%,100%{transform:translateY(0)} 30%{transform:translateY(-4px)} }
.chat-input {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 16px;
  border-top: 1px solid var(--border);
}
.chat-input-placeholder { flex: 1; font-family: var(--font-body); font-size: 13px; color: var(--white-30); }
.chat-send {
  width: 28px; height: 28px;
  background: var(--cyan-dim);
  border: 1px solid var(--border-glow);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 13px; color: var(--cyan); cursor: pointer;
  transition: var(--transition);
}

/* Responsive */
@media (max-width: 1100px) {
  .ref-grid { grid-template-columns: repeat(3, 1fr); }
  .ref-card--featured { grid-column: span 1; }
}
@media (max-width: 768px) {
  .ref-grid { grid-template-columns: repeat(2, 1fr); }
  .sub-nav { display: none; }
  .back-link { font-size: 12px; }
  .site-header-bar { position: relative; }
  .mobile-menu-link { gap: 10px; }
}
@media (max-width: 500px) {
  .ref-grid { grid-template-columns: 1fr; gap: 64px; }
  .ref-card {
    background: rgba(255,255,255,0.04);
    border-color: rgba(255,255,255,0.18);
    box-shadow: 0 10px 30px rgba(0,0,0,0.45);
    position: relative;
  }
  /* gradient линија-сепаратор меѓу картичките */
  .ref-card:not(:last-child)::after {
    content: '';
    position: absolute;
    bottom: -33px;
    left: 15%;
    right: 15%;
    height: 2px;
    border-radius: 2px;
    background: linear-gradient(90deg, transparent, rgba(0,173,241,0.5), rgba(237,0,140,0.5), transparent);
  }
}

/* ============================================================
   PRICING PACKAGES
   ============================================================ */
.pkg-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-top: 40px;
  align-items: start;
}

.pkg-card {
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 20px;
  padding: 28px 24px;
  display: flex;
  flex-direction: column;
}

.pkg-card--featured {
  border-color: var(--magenta);
  background: linear-gradient(135deg, rgba(237,0,140,0.08), rgba(255,255,255,0.04));
  position: relative;
}

.pkg-badge-label {
  display: inline-block;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 4px 12px;
  border-radius: 999px;
  background: var(--magenta);
  color: #fff;
  margin-bottom: 12px;
  align-self: flex-start;
}

.pkg-tier {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.45);
  margin-bottom: 8px;
}

.pkg-price {
  font-size: 44px;
  font-weight: 800;
  color: #fff;
  line-height: 1;
  margin-bottom: 24px;
}

.pkg-features {
  list-style: none;
  margin: 0 0 20px;
  padding: 0;
  flex: 1;
}

.pkg-features li {
  padding: 8px 0;
  font-size: 14px;
  color: rgba(255,255,255,0.75);
  border-bottom: 1px solid rgba(255,255,255,0.06);
  display: flex;
  align-items: flex-start;
  gap: 8px;
  line-height: 1.4;
}

.pkg-features li::before {
  content: '✓';
  color: var(--magenta);
  font-weight: 700;
  flex-shrink: 0;
  margin-top: 1px;
}

.pkg-addons {
  margin-bottom: 20px;
  padding: 14px;
  border-radius: 12px;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.07);
}

.pkg-addons:empty { display: none; }

.pkg-addons-title {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.35);
  margin-bottom: 8px;
}

.pkg-addons ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

.pkg-addons li {
  font-size: 13px;
  color: rgba(255,255,255,0.55);
  padding: 4px 0;
  line-height: 1.4;
}

.pkg-btn {
  width: 100%;
  text-align: center;
  justify-content: center;
  margin-top: auto;
}

@media (max-width: 900px) {
  .pkg-grid { grid-template-columns: 1fr; max-width: 480px; margin-left: auto; margin-right: auto; }
}
