/* trndll.x/tass/pages/styles.css */

*,
*::before,
*::after {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  padding: 0;
  overflow-x: hidden; /* no horizontal scroll */
  font-family: Arial, sans-serif;
}

header,
footer {
  width: 100%;
}

main {
  max-width: 100%;
  overflow-x: hidden;
  min-height: 70vh; /* optional: force height if needed */
}

img, video {
  max-width: 100%;
  height: auto;
  display: block;
}


.block,
section,
div {
  max-width: 100%;
  overflow-x: hidden;
}


/* Optional: Scrollbar styling (optional but neat) */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}
::-webkit-scrollbar-thumb {
  background: #888;
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: #555;
}

#bottomSpacer {
    height:50px;
}

/* Visualiser code start 
 * { box-sizing: border-box; } */
    #theVisualiser {
      margin: 0; padding: 0;
      font-family: Arial, sans-serif;
      height: 100vh;
      display: flex;
      overflow: hidden;
    }

    visualiser-sidebar {
      width: 300px;
      border-right: 1px solid #ddd;
      overflow-y: auto;
    }

    visualiser-canvas {
      flex: 1;
      overflow: auto;
      background: #f9f9f9;
      position: relative;
    }

    visualiser-props {
      width: 300px;
      border-left: 1px solid #ddd;
      overflow-y: auto;
    }

    visualiser-controls {
      position: fixed;
      bottom: 0;
      left: 300px;
      right: 300px; /* aligns with props sidebar */
      background: #fff;
      border-top: 1px solid #ddd;
      padding: 10px;
      text-align: right;
      z-index: 10; /* ensures it stays above canvas elements */
    }

    /* ✅ Floating New Page Button */
    #newPageBtn {
      position: fixed;
      bottom: 80px;
      right: 320px; /* props width + margin */
      background: #04AA6D;
      color: #fff;
      border: none;
      padding: 12px 16px;
      border-radius: 50%;
      font-size: 18px;
      cursor: pointer;
      box-shadow: 0 4px 6px rgba(0,0,0,0.2);
      z-index: 11; /* stays above everything */
    }

    #newPageBtn:hover {
      background: #028e5e;
    }

    /* post visualiser starts */

     * { box-sizing: border-box; }
    body, html {
      margin: 0; padding: 0;
      font-family: Arial, sans-serif;
      height: 100vh; display: flex;
    }
    .sidebar {
      width: 300px; background: #f4f4f4;
      padding: 16px; border-right: 1px solid #ddd;
      overflow-y: auto;
    }
    .sidebar input, .sidebar select {
      width: 100%; padding: 8px;
      margin-bottom: 12px;
      border: 1px solid #ccc;
    }
    .sidebar ul {
      list-style: none; padding: 0;
    }
    .sidebar li {
      margin-top: -1px; background-color: #f6f6f6;
      padding: 12px; font-size: 16px;
      color: black; border: 1px solid #ddd;
      cursor: pointer;
    }
    .sidebar li:hover {
      background-color: #eee;
    }
    .preview {
      flex: 1; padding: 16px;
    }
    .resizable-container {
      width: 100%; max-width: 100%;
      height: auto; resize: both;
      overflow: auto;
      border: 1px dashed #aaa;
      min-width: 320px;
      min-height: 300px;
    }
    .resizable-container iframe {
      width: 100%; height: 100%;
      border: none;
    }
    .code-preview {
      margin-top: 16px;
    }
    .code-preview textarea {
      width: 100%; height: 100px;
      font-family: monospace;
      padding: 8px;
      border: 1px solid #ccc;
    }
    .copy-btn {
      margin-top: 8px; padding: 6px 12px;
      background: #04AA6D; color: #fff;
      border: none; cursor: pointer;
    }

    /* CRUD POSTS STRATS */
    #cudPosts { font-family: Arial, sans-serif; margin: 20px; max-width: 500px; }
    input, textarea, select { width: 100%; margin: 10px 0; padding: 10px; font-size: 16px; }
    label { font-weight: bold; margin-top: 20px; display: block; }
    .actions { margin-top: 20px; display: flex; gap: 10px; flex-wrap: wrap; }
    button { padding: 10px 20px; font-size: 16px; cursor: pointer; }
    .modal { display: none; position: fixed; z-index: 9999; left: 0; top: 0; width: 100%; height: 100%; background: rgba(0,0,0,0.7); overflow: auto; }
    .modal-content { background: #fff; margin: 5% auto; padding: 20px; max-width: 90%; }
    .media-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 10px; margin-top: 20px; }
    .media-grid img, .media-grid video, .media-grid audio { width: 100%; cursor: pointer; border: 2px solid #ddd; }