*,
::after,
::before {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* Global Custom Scrollbars for All Elements */
* {
  scrollbar-width: thin;
  scrollbar-color: rgba(140, 140, 140, 0.45) transparent;
}

::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

::-webkit-scrollbar-track {
  background: transparent;
}

::-webkit-scrollbar-thumb {
  background-color: rgba(140, 140, 140, 0.4);
  border-radius: 10px;
  border: 2px solid transparent;
  background-clip: content-box;
  transition: background-color 0.2s ease;
}

::-webkit-scrollbar-thumb:hover {
  background-color: #0084ff;
  border: 0px solid transparent;
  background-clip: border-box;
}

::-webkit-scrollbar-corner {
  background: transparent;
}
:root {
  --bg-0: #000;
  --bg-1: #fff;
  --bg-2: #eee;
  --bg-3: #000;
  --bg-4: rgba(255, 255, 255, 0.6);
  --text-0: #fff;
  --text-1: #000;
  --ff: "roboto", sans-serif;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg-0: #eee;
    --bg-1: #000000;
    --bg-2: #242424;
    --bg-3: #e6e6e6;
    --bg-4: rgba(0, 0, 0, 0.6);
    --text-0: #000000;
    --text-1: #eee;
  }
}

body {
  font-family: var(--ff);
  color: var(--text-1);
}

.gdoop-logo-icon {
  fill: var(--bg-0);
}

/* header */
header {
  top: 0;
  position: sticky;
  position: -webkit-sticky;
  z-index: 2;
  background: var(--bg-4);
  backdrop-filter: blur(50px);
}
header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.5rem;
}
header .container .left {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
header .sidebar-toggle-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  cursor: pointer;
  color: var(--text-1);
  margin-right: 0.2rem;
  transition: background-color 0.2s;
}
header .sidebar-toggle-btn:hover {
  background: var(--bg-2);
}
header .container .left .logo {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  text-decoration: none;
}
header .container .left .logo svg {
  width: 36px;
  fill: var(--bg-0);
}
header .container .left .logo h4 {
  font-size: 1.5em;
  color: var(--text-1);
}
header .container .right {
  display: flex;
  align-items: center;
  gap: 0.3rem;
}
header .container .right .add-icon,
header .container .right .apps-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: none;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  cursor: pointer;
  color: var(--text-1);
}
header .container .right .apps-icon {
  margin-right: 0.5rem;
}
header .container .right .add-icon:hover,
header .container .right .apps-icon:hover {
  background: var(--bg-2);
}
header .container .right .add-icon svg,
header .container .right .apps-icon svg {
  display: block;
}
header .signin-btn {
  text-decoration: none;
  background: var(--bg-0);
  color: var(--text-0);
  padding: 0.5rem 1rem;
  border-radius: 50px;
  font-weight: 500;
  font-size: 14px;
}
header .user-avatar-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: #0084ff;
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 15px;
  text-decoration: none;
  cursor: pointer;
  flex-shrink: 0;
  overflow: hidden;
}

header .user-avatar-btn img.header-avatar-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* footer */
footer .container {
  padding: 1rem;
  color: #808080;
  text-align: center;
  font-size: 13px;
  max-width: 800px;
  margin: 1rem auto;
}
footer .container a {
  text-decoration: none;
  color: #808080;
  margin-right: 0.3rem;
}

/* Create Modal Popup Overlay */
.gdoop-create-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(0, 0, 0, 0.65);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 100000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition:
    opacity 0.25s ease,
    visibility 0.25s ease;
}

.gdoop-create-overlay.active {
  opacity: 1;
  visibility: visible;
}

.gdoop-create-modal {
  background: var(--bg-1);
  color: var(--text-1);
  border-radius: 20px;
  width: 90%;
  max-width: 520px;
  padding: 1.8rem;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
  transform: scale(0.92);
}

.gdoop-create-overlay.active .gdoop-create-modal {
  transform: scale(1);
}

.gdoop-create-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.5rem;
}

.gdoop-create-header h3 {
  font-size: 22px;
  font-weight: 700;
  margin: 0;
}

.btn-close-create-modal {
  background: var(--bg-1);
  border: none;
  color: var(--text-1);
  width: 34px;
  height: 34px;
  border-radius: 50%;
  font-size: 26px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  line-height: 1;
}

.gdoop-create-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.75rem;
  max-height: 70vh;
  overflow-y: auto;
  padding-right: 0.2rem;
}

.create-option-card {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  text-decoration: none;
  color: var(--text-1);
  padding: 0.75rem 1rem;
  border-radius: 12px;
  background: var(--bg-2);
  border: 1px solid transparent;
  transition:
    background-color 0.2s,
    border-color 0.2s,
    transform 0.15s;
}

.create-option-card:hover {
  background: var(--bg-2);
  border-color: var(--bg-0);
  transform: translateY(-1px);
}

.create-option-icon {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: var(--bg-1);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition:
    background-color 0.2s,
    color 0.2s;
}

.create-option-icon svg {
  width: 20px;
  height: 20px;
  color: var(--text-1);
}

.create-option-card:hover .create-option-icon {
  background: #0084ff;
}

.create-option-card:hover .create-option-icon svg {
  color: #ffffff;
}

.create-option-card span {
  font-size: 14px;
  font-weight: 600;
  text-align: left;
}

/* Mobile View: Fullscreen on screens <= 768px */
@media (max-width: 768px) {
  .gdoop-create-modal {
    width: 100vw;
    height: 100vh;
    max-width: 100vw;
    border-radius: 0;
    padding: 2rem 1.5rem;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
  }

  .gdoop-create-header {
    margin-bottom: 1.5rem;
  }

  .gdoop-create-header h3 {
    font-size: 26px;
  }

  .btn-close-create-modal {
    width: 40px;
    height: 40px;
    font-size: 26px;
  }

  .gdoop-create-grid {
    grid-template-columns: 1fr;
    gap: 0.75rem;
    max-height: calc(100vh - 100px);
  }

  .create-option-card {
    padding: 0.85rem 1.25rem;
  }

  .create-option-icon {
    width: 44px;
    height: 44px;
  }

  .create-option-icon svg {
    width: 22px;
    height: 22px;
  }

  .create-option-card span {
    font-size: 15px;
  }
}

/* Small Sign In Popup Modal Overlay */
.gdoop-signin-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(0, 0, 0, 0.65);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 100001;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition:
    opacity 0.25s ease,
    visibility 0.25s ease;
}

.gdoop-signin-overlay.active {
  opacity: 1;
  visibility: visible;
}

.gdoop-signin-modal {
  background: var(--bg-1);
  color: var(--text-1);
  border-radius: 18px;
  width: 90%;
  max-width: 380px;
  padding: 1.5rem;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
  transform: scale(0.92);
  transition: transform 0.25s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  border: 1px solid var(--bg-2);
  text-align: center;
}

.gdoop-signin-overlay.active .gdoop-signin-modal {
  transform: scale(1);
}

.gdoop-signin-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1rem;
}

.gdoop-signin-header h3 {
  font-size: 18px;
  font-weight: 700;
  margin: 0;
}

.btn-close-signin-modal {
  background: var(--bg-2);
  border: none;
  color: var(--text-1);
  width: 30px;
  height: 30px;
  border-radius: 50%;
  font-size: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  line-height: 1;
}

.gdoop-signin-body p {
  font-size: 14px;
  color: var(--text-1);
  opacity: 0.75;
  margin-bottom: 1.5rem;
  line-height: 1.4;
}

.gdoop-signin-actions {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.btn-signin-primary {
  background: var(--bg-0);
  color: var(--bg-1);
  padding: 0.75rem 1.2rem;
  border-radius: 50px;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  display: block;
  transition:
    opacity 0.2s,
    transform 0.1s;
}

.btn-signin-primary:hover {
  opacity: 0.9;
  transform: translateY(-1px);
}

.btn-signin-cancel {
  background: transparent;
  color: var(--text-1);
  border: none;
  padding: 0.6rem;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  opacity: 0.7;
}

.btn-signin-cancel:hover {
  opacity: 1;
}
