:root {
    --primary: #36004c;     /* 30% color */
    --accent: #fed700;      /* 10% color */
    --bg: #f5f5f7;          /* 60% color - light */
    --text: #1a1a1a;
    --surface: #ffffff;
    --border: #e0e0e0;
  }

  [data-theme="dark"] {
    --bg: #121016;
    --text: #f0f0f0;
    --surface: #1e1b24;
    --border: #332b3d;
  }

  * { box-sizing: border-box; margin: 0; padding: 0; }

  body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    background: var(--bg);
    color: var(--text);
    transition: background 0.3s ease, color 0.3s ease;
    display: flex;
    min-height: 100vh;
  }

  /* NAVBAR */
  .navbar {
    position: fixed;
    top: 0; left: 0; right: 0;
    height: 60px;
    background: var(--primary);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 1rem;
    z-index: 1000;
    box-shadow: 0 2px 8px rgba(0,0,0,0.2);
  }

  .navbar-left {
    display: flex;
    align-items: center;
    gap: 1rem;
  }

  .menu-toggle {
    display: none;
    background: none;
    border: none;
    color: #fff;
    font-size: 1.5rem;
    cursor: pointer;
    padding: 0.25rem 0.5rem;
    border-radius: 6px;
  }

  .menu-toggle:hover { background: rgba(255,255,255,0.1); }

  .navbar-seal {
    height: 40px;
    width: 40px;
    object-fit: contain;
  }

  .navbar-title {
    font-weight: 700;
    font-size: 1.2rem;
    letter-spacing: 0.5px;
  }

  .navbar-title span { color: var(--accent); }

  .theme-switch {
    background: var(--accent);
    color: var(--primary);
    border: none;
    border-radius: 20px;
    padding: 0.5rem 1rem;
    font-weight: 600;
    cursor: pointer;
    font-size: 0.85rem;
    transition: transform 0.2s ease, opacity 0.2s ease;
  }

  .theme-switch:hover { opacity: 0.85; transform: scale(1.03); }

  /* SIDEBAR */
  .sidebar {
    position: fixed;
    top: 60px;
    left: 0;
    bottom: 0;
    width: 250px;
    background: var(--surface);
    border-right: 1px solid var(--border);
    overflow-y: auto;
    z-index: 900;
    transition: transform 0.3s ease;
  }

  .sidebar-nav {
    list-style: none;
    padding: 1rem 0;
  }

  .sidebar-nav a {
    display: block;
    padding: 0.75rem 1.5rem;
    color: var(--text);
    text-decoration: none;
    font-weight: 500;
    transition: background 0.2s ease, color 0.2s ease;
  }

  .sidebar-nav a:hover {
    background: var(--primary);
    color: #fff;
  }

  .sidebar-nav a.active {
    background: var(--accent);
    color: var(--primary);
    font-weight: 700;
  }

  /* Submenu */
  .has-submenu > .submenu-toggle {
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
  }

  .submenu-toggle .arrow {
    transition: transform 0.25s ease;
    font-size: 0.75rem;
  }

  .has-submenu.open .arrow {
    transform: rotate(90deg);
  }

  .submenu {
    list-style: none;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
    background: var(--bg);
  }

  .has-submenu.open .submenu {
    max-height: 500px;
  }

  .submenu a {
    padding-left: 2.5rem;
    font-size: 0.92rem;
    font-weight: 400;
  }

  /* MAIN CONTENT */
  .main-content {
    margin-left: 250px;
    margin-top: 60px;
    padding: 2rem;
    width: 100%;
    transition: margin-left 0.3s ease;
  }

  .page {
    display: none;
    animation: fadeIn 0.3s ease;
  }

  .page.active { display: block; }

  @keyframes fadeIn {
    from { opacity: 0; transform: translateY(8px); }
    to { opacity: 1; transform: translateY(0); }
  }

  .home-hero {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    flex-wrap: wrap;
  }

  .home-seal {
    width: 120px;
    height: 120px;
    object-fit: contain;
    flex-shrink: 0;
  }

  .page h1 {
    color: var(--primary);
    margin-bottom: 0.5rem;
    border-bottom: 4px solid var(--accent);
    display: inline-block;
    padding-bottom: 0.25rem;
  }

  [data-theme="dark"] .page h1 { color: var(--accent); }

  .page p {
    margin-top: 1rem;
    line-height: 1.6;
    max-width: 700px;
  }

  .card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 1.5rem;
    margin-top: 1.5rem;
    box-shadow: 0 2px 6px rgba(0,0,0,0.05);
  }

  .card h3 { color: var(--primary); margin-bottom: 0.5rem; }
  [data-theme="dark"] .card h3 { color: var(--accent); }

  .social-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    margin-top: 0.5rem;
  }

  .social-link {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.6rem 1rem;
    border-radius: 8px;
    text-decoration: none;
    color: var(--text);
    background: var(--bg);
    border: 1px solid var(--border);
    font-weight: 500;
    transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
  }

  .social-link:hover {
    background: var(--primary);
    color: #fff;
    transform: translateX(4px);
  }

  .social-icon {
    font-size: 1.1rem;
    display: flex;
    align-items: center;
  }

  .overlay {
    display: none;
    position: fixed;
    top: 60px; left: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,0.5);
    z-index: 800;
  }

  /* ANNOUNCEMENT CARDS */
  .announcement-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 1.5rem;
    margin-top: 1.5rem;
    box-shadow: 0 2px 6px rgba(0,0,0,0.05);
    display: flex;
    gap: 1.5rem;
    align-items: flex-start;
    justify-content: space-between;
  }

  .announcement-content {
    flex: 1;
    min-width: 0;
  }

  .announcement-content h3 {
    color: var(--primary);
    margin-bottom: 0.25rem;
    font-size: 1.1rem;
  }

  [data-theme="dark"] .announcement-content h3 { color: var(--accent); }

  .announcement-datetime {
    font-size: 0.85rem;
    color: var(--text);
    opacity: 0.65;
    margin-bottom: 0.75rem;
  }

  .announcement-content p {
    line-height: 1.6;
    max-width: 600px;
  }

  .announcement-id-row {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-top: 1rem;
    flex-wrap: wrap;
  }

  .announcement-id {
    font-family: "SFMono-Regular", Consolas, "Liberation Mono", Menlo, monospace;
    font-size: 0.8rem;
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: 6px;
    padding: 0.3rem 0.6rem;
    color: var(--text);
    opacity: 0.8;
  }

  .copy-id-btn {
    background: var(--accent);
    color: var(--primary);
    border: none;
    border-radius: 6px;
    padding: 0.35rem 0.8rem;
    font-size: 0.8rem;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.15s ease, opacity 0.2s ease;
  }

  .copy-id-btn:hover { opacity: 0.85; transform: scale(1.03); }

  .copy-id-btn.copied {
    background: #2ecc71;
    color: #fff;
  }

  .announcement-image {
    flex-shrink: 0;
    width: 160px;
    height: 120px;
    border-radius: 10px;
    background: var(--bg);
    border: 1px dashed var(--border);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text);
    opacity: 0.5;
    font-size: 0.8rem;
    text-align: center;
    overflow: hidden;
  }

  .announcement-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
  }

  @media (max-width: 600px) {
    .announcement-card {
      flex-direction: column;
    }

    .announcement-image {
      width: 100%;
      height: 160px;
      order: 2;
    }

    .announcement-content {
      order: 1;
    }
  }

  /* GALLERY - SNAPS */
  .gallery-container {
    margin-top: 2rem;
  }

  .gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 1.5rem;
  }

  .gallery-item {
    cursor: pointer;
    border-radius: 12px;
    overflow: hidden;
    background: var(--surface);
    border: 1px solid var(--border);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
  }

  .gallery-item:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 16px rgba(0,0,0,0.12);
  }

  .gallery-image-wrapper {
    position: relative;
    width: 100%;
    padding-bottom: 100%;
    overflow: hidden;
    background: var(--bg);
  }

  .gallery-image-wrapper img {
    position: absolute;
    top: 0; left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
  }

  .gallery-caption {
    position: absolute;
    bottom: 0; left: 0; right: 0;
    background: linear-gradient(transparent, rgba(0,0,0,0.6));
    color: #fff;
    padding: 1rem 0.75rem 0.5rem;
    font-size: 0.85rem;
    font-weight: 500;
  }

  /* SCROLLS - VERTICAL FEED */
  .scrolls-container {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    margin-top: 2rem;
    max-width: 420px;
  }

  .scroll-item {
    cursor: pointer;
    border-radius: 16px;
    overflow: hidden;
    background: var(--surface);
    border: 1px solid var(--border);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
  }

  .scroll-item:hover {
    box-shadow: 0 8px 16px rgba(0,0,0,0.12);
  }

  .scroll-video-wrapper {
    position: relative;
    width: 100%;
    padding-bottom: 177.78%;
    overflow: hidden;
    background: #000;
  }

  .scroll-video-wrapper video {
    position: absolute;
    top: 0; left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
  }

  .scroll-play-icon {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 3rem;
    color: rgba(255,255,255,0.8);
    pointer-events: none;
    transition: opacity 0.2s ease;
  }

  .scroll-item:hover .scroll-play-icon {
    opacity: 1;
  }

  .scroll-caption {
    position: absolute;
    bottom: 0; left: 0; right: 0;
    background: linear-gradient(transparent, rgba(0,0,0,0.7));
    color: #fff;
    padding: 1.5rem 1rem 1rem;
    font-size: 0.9rem;
    font-weight: 500;
  }

  /* FULLSCREEN MODAL */
  .fullscreen-modal {
    display: none;
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,0.95);
    z-index: 2000;
    align-items: center;
    justify-content: center;
    padding: 2rem 1rem;
  }

  .fullscreen-modal.active {
    display: flex;
  }

  .modal-content {
    position: relative;
    width: 100%;
    max-width: 90vw;
    max-height: 85vh;
    display: flex;
    flex-direction: column;
    align-items: center;
  }

  .snaps-modal-content img {
    width: 100%;
    height: 100%;
    max-height: 80vh;
    object-fit: contain;
    border-radius: 8px;
  }

  .scrolls-modal-content {
    width: 100%;
    max-width: 420px;
  }

  .scrolls-modal-content video {
    width: 100%;
    border-radius: 8px;
    background: #000;
  }

  .modal-caption {
    color: #fff;
    margin-top: 1rem;
    font-size: 1rem;
    text-align: center;
    max-width: 500px;
  }

  .modal-close {
    position: absolute;
    top: 1.5rem;
    right: 1.5rem;
    background: rgba(255,255,255,0.15);
    border: 1px solid rgba(255,255,255,0.3);
    color: #fff;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    font-size: 1.5rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s ease;
    z-index: 2001;
  }

  .modal-close:hover {
    background: rgba(255,255,255,0.25);
  }

  .modal-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255,255,255,0.15);
    border: 1px solid rgba(255,255,255,0.3);
    color: #fff;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    font-size: 2rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s ease;
    z-index: 2001;
  }

  .modal-nav:hover {
    background: rgba(255,255,255,0.25);
  }

  .modal-nav.prev { left: 1.5rem; }
  .modal-nav.next { right: 1.5rem; }

  .modal-download {
    position: absolute;
    bottom: 1.5rem;
    left: 50%;
    transform: translateX(-50%);
    background: var(--accent);
    color: var(--primary);
    border: none;
    border-radius: 6px;
    padding: 0.6rem 1.2rem;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.2s ease, opacity 0.2s ease;
    z-index: 2001;
  }

  .modal-download:hover {
    opacity: 0.9;
    transform: translateX(-50%) scale(1.05);
  }

  /* POSTS FEED */
  .posts-feed {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    margin-top: 2rem;
    max-width: 600px;
  }

  /* FACEBOOK EMBED FORM */
  .facebook-embed-form {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 1.5rem;
    margin-top: 1.5rem;
    box-shadow: 0 2px 6px rgba(0,0,0,0.05);
    display: flex;
    flex-direction: column;
    gap: 1rem;
  }

  .facebook-embed-form textarea {
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 0.75rem;
    font-family: 'Courier New', monospace;
    font-size: 0.85rem;
    color: var(--text);
    resize: vertical;
  }

  .facebook-embed-form textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(54, 0, 76, 0.1);
  }

  [data-theme="dark"] .facebook-embed-form textarea:focus {
    box-shadow: 0 0 0 3px rgba(254, 215, 0, 0.15);
  }

  .facebook-embed-form button {
    background: var(--primary);
    color: #fff;
    border: none;
    border-radius: 8px;
    padding: 0.75rem 1.5rem;
    font-weight: 600;
    font-size: 0.95rem;
    cursor: pointer;
    transition: background 0.2s ease, transform 0.2s ease;
  }

  .facebook-embed-form button:hover {
    background: #2d0040;
    transform: translateY(-2px);
  }

  [data-theme="dark"] .facebook-embed-form button {
    background: var(--accent);
    color: var(--primary);
  }

  [data-theme="dark"] .facebook-embed-form button:hover {
    background: #f0d000;
  }

  /* FACEBOOK POST WRAPPER */
  .facebook-post-wrapper {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 6px rgba(0,0,0,0.05);
    margin-top: 1.5rem;
  }

  .fb-post-container {
    width: 100%;
  }

  .facebook-post-wrapper .fb-post {
    width: 100% !important;
  }

  .facebook-post-wrapper .fb:post {
    width: 100% !important;
  }

  .facebook-post-wrapper iframe {
    width: 100% !important;
    border: none !important;
    display: block;
  }

  .fb_iframe_widget {
    width: 100% !important;
  }

  .fb_iframe_widget span {
    width: 100% !important;
  }

  .post-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 6px rgba(0,0,0,0.05);
  }

  .post-header {
    padding: 1rem 1.25rem;
    border-bottom: 1px solid var(--border);
  }

  .post-author-info {
    display: flex;
    align-items: center;
    gap: 0.75rem;
  }

  .post-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--primary);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1.1rem;
  }

  .post-author {
    font-weight: 600;
    color: var(--text);
    font-size: 0.95rem;
  }

  .post-source {
    font-size: 0.8rem;
    color: var(--text);
    opacity: 0.6;
    margin-top: 0.15rem;
  }

  .post-body {
    padding: 1rem 1.25rem;
  }

  .post-content {
    line-height: 1.6;
    color: var(--text);
    margin-bottom: 1rem;
  }

  .post-image {
    width: 100%;
    border-radius: 8px;
    max-height: 400px;
    object-fit: cover;
  }

  .post-footer {
    display: flex;
    border-top: 1px solid var(--border);
    padding: 0.75rem 1.25rem;
    gap: 0.5rem;
  }

  .post-action {
    flex: 1;
    background: none;
    border: none;
    padding: 0.5rem;
    color: var(--text);
    opacity: 0.7;
    font-size: 0.9rem;
    cursor: pointer;
    border-radius: 6px;
    transition: background 0.2s ease, opacity 0.2s ease;
  }

  .post-action:hover {
    opacity: 1;
    background: var(--bg);
  }

  /* MOBILE */
  @media (max-width: 850px) {
    .menu-toggle { display: inline-block; }

    .sidebar {
      transform: translateX(-100%);
      width: 250px;
    }

    .sidebar.open { transform: translateX(0); }

    .main-content { margin-left: 0; padding: 1.5rem; }

    .overlay.show { display: block; }

    .gallery-grid {
      grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
      gap: 1rem;
    }

    .modal-nav {
      width: 40px;
      height: 40px;
      font-size: 1.5rem;
    }

    .modal-nav.prev { left: 0.75rem; }
    .modal-nav.next { right: 0.75rem; }

    .modal-close {
      width: 36px;
      height: 36px;
      font-size: 1.25rem;
      top: 1rem;
      right: 1rem;
    }

    .scrolls-container {
      max-width: 100%;
    }

    .posts-feed {
      max-width: 100%;
    }
  }

  @media (max-width: 600px) {
    .modal-content {
      max-width: 100vw;
      max-height: 90vh;
    }

    .snaps-modal-content img {
      max-height: 85vh;
    }

    .modal-download {
      bottom: 1rem;
      padding: 0.5rem 1rem;
      font-size: 0.9rem;
    }

    .post-header, .post-body, .post-footer {
      padding: 0.75rem 1rem;
    }
  }