 *, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }



:root {
    --bg: #0c0c0e;
    --bg2: #141417;
    --bg3: #1c1c21;
    --surface: #1e1e24;
    --surface2: #27272f;
    --border: rgba(255,255,255,0.08);
    --border2: rgba(255,255,255,0.14);
    --text: #f0efe8;
    --text2: #9c9b94;
    --text3: #5a5a62;
    --accent: #e8c97a;
    --accent2: #c4a240;
    --accent-bg: rgba(232,201,122,0.08);
    --pink: #e87a9c;
    --teal: #7adce8;
    --radius: 12px;
    --radius-sm: 8px;

  }

  body {
    font-family: 'DM Sans', sans-serif;
    background: var(--bg);
    color: var(--text);
    min-height: 100vh;
    overflow-x: hidden;
    box-sizing: border-box;
  

  }

  /* HEADER */
  header {
    position:sticky;
    top: 0;
    z-index: 100;
    background: rgba(12,12,14,0.92);
    backdrop-filter: blur(16px);
    border-bottom: 0.5px solid var(--border);
    padding: 0 2rem; 
  }

  .header-inner {
    position:sticky;
  
    max-width: 1900px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 64px;
    gap: 2rem;
  }

  .logo {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
  }

  .logo-icon {
    width: 34px;
    height: 34px;
    background: var(--accent);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
  }

  .logo-icon svg { color: #0c0c0e; }

  .logo-text {
    font-family: 'DM Serif Display', serif;
    font-size: 20px;
    color: var(--text);
    letter-spacing: -0.3px;
  }

  nav {
    display:flex;
    align-items: center;
    gap: 4px;
    background: var(--bg3);
    border: 0.5px solid var(--border);
    border-radius: 10px;
    padding: 4px;
  }

  nav button {
    font-family: 'DM Sans', sans-serif;
    font-size: 13px;
    font-weight: 500;
    color: var(--text2);
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 6px 14px;
    border-radius: 7px;
    transition: all 0.15s;
  }

  nav button:hover { color: var(--text); background: var(--surface2); }

  nav button.active {
    background: var(--surface2);
    color: var(--accent);
    border: 0.5px solid var(--border2);
  }

  .header-right{ 
    display: flex;
    align-items: center;
    gap: 12px;

   }

  .btn-add {
    display: flex;
    align-items: center;
    gap: 8px;
    font-family: 'DM Sans', sans-serif;
    font-size: 13px;
    font-weight: 600;
    background:var(--accent);
    color: #0c0c0e;
    border: none;
    border-radius: var(--radius-sm);
    padding: 8px 16px;
    cursor: pointer;
    transition: all 0.15s;
    letter-spacing: 0.1px;
  }

  .btn-add:hover { background: #f2d98e; transform: translateY(-1px); }
  .btn-add:active { transform: translateY(0); }

  /* HERO STRIP */
  .hero {
    border-bottom: 0.5px solid var(--border);
    padding: 3.5rem 2rem 3rem;
    text-align: center;
    background: radial-gradient(ellipse 60% 40% at 50% -10%, rgba(232,201,122,0.07) 0%, transparent 70%);
  }

  .hero-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 1.4px;
    text-transform: uppercase;
    color: var(--accent);
    background: var(--accent-bg);
    border: 0.5px solid rgba(232,201,122,0.2);
    padding: 4px 12px;
    border-radius: 100px;
    margin-bottom: 1.25rem;
  }

  .hero h1 {
    font-family: 'DM Serif Display', serif;
    font-size: clamp(2rem, 5vw, 3.4rem);
    color: var(--text);
    line-height: 1.12;
    letter-spacing: -1px;
    margin-bottom: 1rem;
  }

  .hero h1 em { font-style: italic; color: var(--accent); }

  .hero p {
    font-size: 15px;
    color: var(--text2);
    max-width: 480px;
    margin: 0 auto;
    line-height: 1.65;
  }

  /* STATS */
  .stats {
    display: flex;
    justify-content: center;
    gap: 2.5rem;
    margin-top: 2rem;
  }

  .stat { text-align: center; }

  .stat-num {
    font-family: 'DM Serif Display', serif;
    font-size: 1.5rem;
    color: var(--text);
  }

  .stat-label {
    font-size: 12px;
    color: var(--text3);
    margin-top: 2px;
  }

  /* SECTION TABS */
  .section-bar {
    max-width: 1280px;
    margin: 0 auto;
    padding: 2rem 2rem 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
  }

  .section-tabs {
    display: flex;
    gap: 0;
    border-bottom: 0.5px solid var(--border);
  }

  .section-tab {
    font-family: 'DM Sans', sans-serif;
    font-size: 13px;
    font-weight: 500;
    color: var(--text2);
    background: none;
    border: none;
    border-bottom: 2px solid transparent;
    padding: 10px 18px;
    cursor: pointer;
    transition: all 0.15s;
    margin-bottom: -0.5px;
    display: flex;
    align-items: center;
    gap: 7px;
  }

  .section-tab:hover { color: var(--text); }

  .section-tab.active {
    color: var(--accent);
    border-bottom-color: var(--accent);
  }

  .tab-count {
    font-size: 10px;
    font-weight: 600;
    background: var(--bg3);
    color: var(--text3);
    padding: 2px 7px;
    border-radius: 100px;
    border: 0.5px solid var(--border);
  }

  .section-tab.active .tab-count { color: var(--accent); background: var(--accent-bg); border-color: rgba(232,201,122,0.2); }

  .search-wrap {
    display: flex;
    align-items: center;
    gap: 8px;
    background: var(--accent);
    border: 0.5px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 7px 12px;
  }

  .search-wrap svg { color: var(--text3); flex-shrink: 0; }

  .search-wrap input {
    font-family: 'DM Sans', sans-serif;
    font-size: 13px;
    background: none;
    border: none;
    outline: none;
    color: var(--text);
    width: 200px;
  }

  .search-wrap input::placeholder { color: var(--text3); }

  /* GRID */
  .grid-wrap {
    max-width: 1280px;
    margin: 0 auto;
    padding: 1.75rem 2rem 4rem;
  }

  .prompt-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.25rem;
  }

  /* CARD */
  .card {
    background: var(--surface);
    border: 0.5px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
    transition: all 0.2s;
    cursor: pointer;
    position: relative;
    height: fit-content;
  }

  .card:hover {
    border-color: var(--border2);
    transform: translateY(-3px);
    box-shadow: 0 16px 48px rgba(0,0,0,0.4);
  }

  .card-media {
    width: 100%;
    aspect-ratio: 4/3;
    overflow: hidden;
    position: relative;
    background: var(--bg3);
  }

  .card-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.4s;
  }

  .card:hover .card-media img { transform: scale(1.04); }

  .card-media-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    color: var(--text3);
  }

  .card-media-placeholder svg { opacity: 0.35; }
  .card-media-placeholder span { font-size: 11px; opacity: 0.5; }

  .video-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 10px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    color: var(--teal);
    background: rgba(10,10,14,0.8);
    border: 0.5px solid rgba(122,220,232,0.25);
    padding: 3px 8px;
    border-radius: 6px;
    backdrop-filter: blur(8px);
  }

  .card-actions-overlay {
    position: absolute;
    top: 10px;
    right: 10px;
    display: flex;
    gap: 6px;
    opacity: 0;
    transition: opacity 0.2s;
  }

  .card:hover .card-actions-overlay { opacity: 1; }

  .icon-btn {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(12,12,14,0.85);
    border: 0.5px solid var(--border2);
    border-radius: 8px;
    color: var(--text2);
    cursor: pointer;
    transition: all 0.15s;
    backdrop-filter: blur(8px);
  }

  .icon-btn:hover { background: var(--bg2); color: var(--accent); border-color: rgba(232,201,122,0.3); }
  .icon-btn.liked { color: var(--pink); }

  .card-body {
    padding: 1rem 1rem 0.875rem;
    overflow: hidden;
    transition:max-height 0.4s ease;
  

    
  }

  .card-meta {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 0.6rem;
  }

  .category-pill {
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 0.6px;
    text-transform: uppercase;
    padding: 2px 8px;
    border-radius: 100px;
  }

  .pill-photo { background: rgba(232,201,122,0.1); color: var(--accent); border: 0.5px solid rgba(232,201,122,0.2); }
  .pill-video { background: rgba(122,220,232,0.1); color: var(--teal); border: 0.5px solid rgba(122,220,232,0.2); }
  .pill-art { background: rgba(232,122,156,0.1); color: var(--pink); border: 0.5px solid rgba(232,122,156,0.2); }

  .card-time { font-size: 11px; color: var(--text3); margin-left: auto; }

  .card-prompt {
    font-size: 13px;
    color: var(--text2);
    line-height: 1.6;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin-bottom: 0.875rem;
    min-height:62px;
  }

  .card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 0.75rem;
    border-top: 0.5px solid var(--border);
  }

  .author {
    display: flex;
    align-items: center;
    gap: 7px;
  }

  .avatar {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 10px;
    font-weight: 600;
    flex-shrink: 0;
  }

  .author-name { font-size: 12px; color: var(--text2); }

  .card-btns {
    display: flex;
    gap: 6px;
  }

  .card-btn {
    display: flex;
    align-items: center;
    gap: 5px;
    font-family: 'DM Sans', sans-serif;
    font-size: 11px;
    font-weight: 500;
    color: var(--text2);
    background: var(--bg3);
    border: 0.5px solid var(--border);
    border-radius: 6px;
    padding: 5px 9px;
    cursor: pointer;
    transition: all 0.15s;
  }

  .card-btn:hover { color: var(--accent); border-color: rgba(232,201,122,0.3); }
  .card-btn.copied { color: #7adce8; border-color: rgba(122,220,232,0.3); }

  /* EMPTY STATE */
  .empty-state {
    grid-column: 1/-1;
    text-align: center;
    padding: 5rem 2rem;
    color: var(--text3);
  }

  .empty-state svg { margin-bottom: 1rem; opacity: 0.3; }
  .empty-state h3 { font-size: 1rem; color: var(--text2); margin-bottom: 0.5rem; }
  .empty-state p { font-size: 13px; line-height: 1.6; }

  /* MODAL BACKDROP */
  .modal-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.75);
    z-index: 200;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    backdrop-filter: blur(4px);
  }

  .modal-backdrop.open { display: flex; }

  .modal {
    background: var(--);
    border: 0.5px solid var(--border2);
    border-radius: 16px;
    width: 100%;
    max-width: 560px;
    padding: 2rem;
    position: relative;
    animation: slideUp 0.22s ease;
  
  }
   
.modal{
    max-height: 90vh;
    overflow-y: scroll;
   }

.modal::-webkit-scrollbar{
    display: none;
}   


  @keyframes slideUp {
    from { opacity: 0; transform: translateY(12px); }
    to { opacity: 1; transform: translateY(0); }
  }

  .modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1.75rem;
  }

  .modal-title {
    font-family: 'DM Serif Display', serif;
    font-size: 1.4rem;
    color: var(--text);
  }

  .modal-close {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    border: 0.5px solid var(--border);
    background: var(--bg3);
    color: var(--text2);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.15s;
  }

  .modal-close:hover { color: var(--text); border-color: var(--border2); }

  label {
    display: block;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.4px;
    text-transform: uppercase;
    color: var(--text3);
    margin-bottom: 6px;
  }

  .form-group { margin-bottom: 1.25rem; }

  input[type="text"], input[type="url"], textarea, select {
    width: 100%;
    background: var(--bg3);
    border: 0.5px solid var(--border2);
    border-radius: var(--radius-sm);
    color: var(--text);
    font-family: 'DM Sans', sans-serif;
    font-size: 14px;
    padding: 10px 14px;
    outline: none;
    transition: border-color 0.15s;
    
  }

  input[type="text"]:focus, input[type="url"]:focus, textarea:focus, select:focus {
    border-color: var(--accent2);
  }

  textarea { resize: vertical; min-height: 100px; line-height: 1.6; }
  select { cursor: pointer; appearance: none; }

  input::placeholder, textarea::placeholder { color: var(--text3); }

  .type-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
  }

  .type-option {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 14px;
    border: 0.5px solid var(--border);
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: all 0.15s;
    background: var(--bg3);
  }

  .type-option:hover { border-color: var(--border2); }
  .type-option.selected { border-color: var(--accent2); background: var(--accent-bg); }

  .type-option input { display: none; }

  .type-icon {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--surface2);
  }

  .type-label { font-size: 13px; font-weight: 500; color: var(--text2); }
  .type-option.selected .type-label { color: var(--accent); }

  .modal-footer {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
    margin-top: 1.75rem;
  }

  .btn-cancel {
    font-family: 'DM Sans', sans-serif;
    font-size: 13px;
    font-weight: 500;
    background: transparent;
    border: 0.5px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--text2);
    padding: 9px 18px;
    cursor: pointer;
    transition: all 0.15s;
  }

  .btn-cancel:hover { border-color: var(--border2); color: var(--text); }

  .btn-submit {
    font-family: 'DM Sans', sans-serif;
    font-size: 13px;
    font-weight: 600;
    background: var(--accent);
    color: #0c0c0e;
    border: none;
    border-radius: var(--radius-sm);
    padding: 9px 24px;
    cursor: pointer;
    transition: all 0.15s;
  }

  .btn-submit:hover { background: #f2d98e; }

  /* DETAIL MODAL */
  .detail-modal {
    max-width: 680px;
  }

  .detail-image {
    width: 100%;
    border-radius: var(--radius-sm);
    overflow: hidden;
    margin-bottom: 1.25rem;
    aspect-ratio: 16/9;
    background: var(--bg3);
    display: flex;
    align-items: center;
    justify-content: center;
  }

  .detail-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
  }

  .detail-prompt-box {
    background: var(--bg3);
    border: 0.5px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 1rem;
    font-size: 14px;
    line-height: 1.7;
    color: var(--text2);
    margin-bottom: 1rem;
    white-space: pre-wrap;
    word-break: break-word;
  }

  .detail-actions { display: flex; gap: 10px; flex-wrap: wrap; }

  .detail-btn {
    display: flex;
    align-items: center;
    gap: 7px;
    font-family: 'DM Sans', sans-serif;
    font-size: 13px;
    font-weight: 500;
    padding: 9px 18px;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: all 0.15s;
  }

  .detail-btn-primary { background: var(--accent); color: #0c0c0e; border: none; font-weight: 600; }
  .detail-btn-primary:hover { background: #f2d98e; }
  .detail-btn-secondary { background: transparent; border: 0.5px solid var(--border); color: var(--text2); }
  .detail-btn-secondary:hover { border-color: var(--border2); color: var(--text); }

  .toast {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    background: var(--surface2);
    border: 0.5px solid var(--border2);
    border-radius: var(--radius-sm);
    padding: 12px 18px;
    font-size: 13px;
    color: var(--text);
    display: flex;
    align-items: center;
    gap: 8px;
    z-index: 1000;
    opacity: 0;
    transform: translateY(8px);
    transition: all 0.2s;
    pointer-events: none;
  }

  .toast.show { opacity: 1; transform: translateY(0); }

  .upload-zone {
    border: 1.5px dashed var(--border2);
    border-radius: var(--radius-sm);
    padding: 2rem;
    text-align: center;
    cursor: pointer;
    transition: all 0.15s;
    background: var(--bg3);
    position: relative;
  }

  .upload-zone:hover { border-color: var(--accent2); background: var(--accent-bg); }
  .upload-zone p { font-size: 13px; color: var(--text3); margin-top: 8px; }
  .upload-zone input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }

  .upload-preview {
    width: 100%;
    border-radius: var(--radius-sm);
    max-height: 180px;
    object-fit: cover;
    display: none;
    margin-top: 10px;
  }

  @media (max-width: 640px) {
    .hero h1 { font-size: 1.9rem; }
    .stats { gap: 1.5rem; }
    nav { display: none; }
    .prompt-grid { grid-template-columns: 1fr 1fr; }
    .type-row { grid-template-columns: 1fr 1fr; }
    .header-inner { padding: 0; }
    header { padding: 0 1rem; }
    .hero { padding: 2.5rem 1rem 2rem; }
    .grid-wrap { padding: 1.25rem 1rem 3rem; }
    .section-bar { padding: 1.5rem 1rem 0; }
    .search-wrap input { width: 140px; }
  }

#BUT{
    width: 25px;
    height: 25px;
    border-radius: 30px;
    border: none;
    background-color: #c4a240;
    box-shadow: 1px 1px 2px black;
}

#BUT:active{

    background-color: #f0efe8;

    transition: 0.5s;

}

#BUT:hover{
    background-color: #e8c97a;
}

.profile_page{
  display: none;
  position: fixed;
    background: white;
  

    top:70px;
    right:20px;

    width:70vh;
    height:70vh;

  z-index: 1000;
   background: rgba(40, 40, 40, 0.01);

    backdrop-filter: blur(10px);
    border-radius: 30px;
    box-shadow: 0 8px 32px rgba(234, 232, 232, 0.1);
}
.profile_button{
  background:var(--accent);
  width: 30px;
  height: 30px;

  cursor: pointer;
  border-radius: 40px;
  background: var(--accent);
  font-size: 27px;
  border: none;

}

.model{
  display: none;
  position: fixed;
  background: rgb(235, 235, 238);
   width: 100vh;
   height: 100%;
   top: 70px;
   left: 10px;
   background:rgba(0, 0, 0, 0.3);
  backdrop-filter: blur(20px);
  box-shadow: 0px 8px 50px rgb(39, 39, 39);
  border-radius: 30px;
  z-index: 1000;
}

@media (max-width: 768px) {
  header{
    width: 100%;
  }

  .header-inner{
    width: 100%;
  }
  .nav{
    width: 100%;
  }
  
}

.arrow-down{
  
  display: flex;
  justify-content: end;
  width: 37vh;
  margin-top:0;
}

.scroll-card{
  background:blue;
  max-height: 0;
  overflow: hidden;
  transition:max-height 0.4s ease;
}
.scroll-card.opener{
  max-height: 500px;
}

#spanp{
  font-size: 28px;
  font-weight: 10px;
}
#json{
  font-size: 11px;
  height: 30px;
  background:var(--accent-bg);

  min-width: 30vh;
  display: flex;
  justify-content: center;
  align-items: center;
  color:var(--text2);
  gap:10px;
  border-radius:16px;
 border: 1px solid rgba(232, 201, 122, 0.2);
}
#jsonspan{
  font-size: 11px;
}
.parent_json{
  background: var(--bg);
  display: flex;
  justify-content: center;
}