/* RESET */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "Inter", system-ui, sans-serif;
}

body {
  background: linear-gradient(180deg, #f8fcff, #eef6f3);
  color: #1f2937;
  min-height: 100vh;
}

/* NAVBAR */

.navbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 24px;
  min-height: 80px;
}

@media (max-width: 768px) {
  .navbar {
    padding: 12px 12px;
    min-height: 60px;
    flex-wrap: wrap;
  }
  
  .navbar .logo {
    padding-left: 0;
    flex-grow: 0;
  }
  
  .navbar .logo img {
    height: 50px;
  }
  
  .auth-buttons {
    gap: 8px;
  }
}

.back-btn {
  position: absolute;
  left: 16px;
  top: 35px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 8px 12px;
  border-radius: 8px; /* same rounded rectangle as profile */
  background: #7bbf4a; /* same as .btn.primary */
  color: #fff;
  text-decoration: none;
  font-weight: 700;
  box-shadow: 0 8px 20px rgba(123, 191, 74, 0.2);
  transition: transform 0.12s ease, box-shadow 0.12s ease;
  z-index: 50;
}

@media (max-width: 768px) {
  .back-btn {
    position: relative;
    left: auto;
    top: auto;
    padding: 6px 10px;
    font-size: 14px;
  }
}

.back-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 28px rgba(123, 191, 74, 0.28);
}

.logo {
  flex-grow: 1;
  display: flex;
  justify-content: center;
  align-items: center;
  padding-left: 80px;
}

.logo img {
  height: 80px;
  width: auto;
  object-fit: contain;
}

.auth-buttons {
  display: flex;
  gap: 12px;
  align-items: center;
  flex-shrink: 0;
}

.btn {
  padding: 8px 16px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 500;
}

.btn.primary {
  background: #7bbf4a;
  color: white;
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 44px;
  min-height: 44px;
  border-radius: 12px;
  font-size: 16px;
  font-weight: 600;
}

.btn.primary.profile-btn {
  padding: 0;
  width: 48px;
  height: 48px;
  border-radius: 14px;
  font-size: 18px;
  background: linear-gradient(135deg, #7bbf4a 0%, #5fa83f 100%);
}


@media (max-width: 768px) {
  .btn {
    padding: 8px 12px;
    font-size: 14px;
  }
  
  .btn.primary {
    min-width: 40px;
    min-height: 40px;
    font-size: 14px;
  }
  
  .create-shelf {
    width: 100%;
    padding: 12px;
    font-size: 14px;
  }
}

@media (max-width: 480px) {
  .btn {
    padding: 6px 10px;
    font-size: 12px;
  }
}

.profile-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 16px rgba(123, 191, 74, 0.2);
}

/* Premium Badge */
.premium-badge {
  position: absolute;
  top: -27px;
  right: -8px;
  font-size: 26px;
  display: inline-block;
}

.premium-badge-crown {
  display: inline-block;
  animation: crownRotate 3s ease-in-out infinite, sparkle 2s ease-in-out infinite;
}

@keyframes crownRotate {
  0%, 100% {
    transform: rotate(-3deg) scale(1);
  }
  50% {
    transform: rotate(3deg) scale(1);
  }
}

@keyframes sparkle {
  0%, 100% {
    opacity: 1;
    filter: drop-shadow(0 0 0px rgba(255, 215, 0, 0));
  }
  50% {
    opacity: 0.7;
    filter: drop-shadow(0 0 8px rgba(255, 215, 0, 0.8));
  }
}

.btn.ghost {
  border: 1px solid #cfdbe8;
  color: #7bbf4a;
}

/* HERO */
.container {
  max-width: 900px;
  margin: 0 auto;
  padding: 40px 20px;
  text-align: center;
}
@media (max-width: 768px) {
  .container {
    padding: 30px 15px;
  }
}

@media (max-width: 480px) {
  .container {
    padding: 20px 10px;
  }
}

.headline {
  font-size: 2.6rem;
  font-weight: 700;
  margin-bottom: 12px;
}


@media (max-width: 768px) {
  h1 {
    font-size: 24px;
    margin-bottom: 10px;
  }
  
  h2 {
    font-size: 20px;
  }
  
  h3 {
    font-size: 18px;
  }
  
  .headline {
    font-size: 22px;
  }
  
  .subtitle {
    font-size: 14px;
  }
}

@media (max-width: 480px) {
  h1 {
    font-size: 20px;
  }
  
  h2 {
    font-size: 18px;
  }
  
  .headline {
    font-size: 18px;
  }
}

.headline span {
  color: #7bbf4a;
}

.subtitle {
  font-size: 1.1rem;
  color: #4b5563;
  margin-bottom: 48px;
}

/* SHELVES */
.shelf-container{
  display: grid;
  grid-template-columns: repeat(2, 1fr); /* 2 columns */
  margin-bottom: 32px;
  gap: 20px;
  max-width: 66%;
  margin-left: 0;
  margin-right: auto;
  padding: 0 40px;
}

/* ACTIVE READING SECTION */
.active-reading-section {
  display: flex;
  justify-content: center;
  margin: 30px auto 40px;
}

.active-reading-btn {
  padding: 16px 32px;
  border-radius: 12px;
  border: none;
  background: linear-gradient(135deg, #7bbf4a, #5a9a2f);
  color: white;
  font-size: 1.1rem;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 0 8px 20px rgba(123, 191, 74, 0.3);
  transition: all 0.3s ease;
  text-decoration: none;
  display: inline-block;
}

.active-reading-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 28px rgba(123, 191, 74, 0.4);
  background: linear-gradient(135deg, #8dcd5c, #6aa838);
  text-decoration: none;
  color: white;
}

.shelf {
  padding: 24px;
  border-radius: 16px;
  border: none;
  font-size: 1.3rem;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 0 10px 30px rgba(0,0,0,0.08);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.shelf:hover {
  transform: translateY(-4px);
  box-shadow: 0 14px 36px rgba(0,0,0,0.12);
}

.dashboard-shelf:nth-child(3n + 1) {
  background:  #eaf6e8;
  color: #4b8f29;
  margin: 20px;
}

.dashboard-shelf:nth-child(3n + 2) {
  background: #eaf6e8;
  color: #4b8f29;
  margin: 20px;
}

.dashboard-shelf:nth-child(3n + 3) {
  background: #eaf6e8;
  color: #4b8f29;
  margin: 20px;
}





.dashboard-shelf {
  height: 120px;              /* SAME HEIGHT */
  display: flex;
  align-items: center;        /* vertical center */
  justify-content: center;    /* horizontal center */
  text-align: center;
  position: relative;
}


.shelf {
  text-decoration: none;
  border-radius: 16px;
  font-size: 1.1rem;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 0 10px 30px rgba(0,0,0,0.08);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.shelf:hover {
  transform: translateY(-4px);
  box-shadow: 0 14px 36px rgba(0,0,0,0.12);
}


.shelf-wrapper {
  margin: 20px;

}


/* CREATE BUTTON */
.create-shelf {
  padding: 14px 28px;
  border-radius: 12px;
  border: 2px dashed #9fd3b5;
  background: #f1fbf6;
  font-size: 1rem;
  font-weight: 600;
  color: #2f855a;
  cursor: pointer;
}

.create-shelf:hover {
  background: #e6f6ee;
}

/* CREATE FORM */
.create-form {
  display: flex;
  gap: 12px;
  justify-content: center;
  margin: 40px auto;
  max-width: 500px;
  padding: 0 20px;
}

.create-form input {
  flex: 1;
  padding: 14px 20px;
  border-radius: 12px;
  border: 2px solid #9fd3b5;
  background: #f1fbf6;
  font-size: 1rem;
  color: #2f855a;
  transition: all 0.3s ease;
  font-weight: 500;
}

.create-form input:focus {
  outline: none;
  border-color: #7bbf4a;
  background: #e6f6ee;
  box-shadow: 0 0 8px rgba(123, 191, 74, 0.2);
}

.create-form input::placeholder {
  color: rgba(75, 143, 41, 0.5);
}

/* MOBILE */
@media (max-width: 600px) {
  .headline {
    font-size: 2rem;
  }

  .navbar {
    flex-direction: column;
    gap: 12px;
  }
}
/* General Styles */


/*log in and sign up page */

.auth-container {
  max-width: 360px;
  margin: 80px auto;
  padding: 32px;
  background: white;
  border-radius: 16px;
  box-shadow: 0 20px 40px rgba(0,0,0,0.1);
  text-align: center;
}

.auth-container h2 {
  margin-bottom: 8px;
}

.auth-container p {
  color: #6b7280;
  margin-bottom: 24px;
}

.auth-container input {
  width: 100%;
  padding: 12px;
  margin-bottom: 16px;
  border-radius: 8px;
  border: 1px solid #d1d5db;
}

.btn.full {
  width: 100%;
}

.switch {
  margin-top: 16px;
  font-size: 0.9rem;
}







.logo-header {
  display: flex;
  justify-content: center;
  align-items: center;
  height: 50px;           /* makes logo area tall */
  margin-bottom: 10px;
  width: 70%;
}

.logo-header img {
  object-fit: contain;
}


/*sign in page*/



.cardlayout{
    width: 100%;
    box-sizing: border-box;
    max-width: 416px;
    box-shadow: unset;
    padding: 0 32px;
    -webkit-box-sizing: border-box;

}

#organic-div{
    background: transparent;
    border: 0;
    font-size: 100%;
    vertical-align: baseline;
    margin: 0;
    padding: 0;
    border: 0;
}

.header_content{
    font-size: 100%;
    vertical-align: baseline;
    margin: 0;
    background: transparent;
    padding: 0;
}


.header_content_heading{
    font-size: 3.1rem;
    line-height: 1.25;
    font-weight: 600;
    color: rgba(0,0,0,0.9);
    padding:0 0 4px 0;

}


.login_form{
    margin: auto;
    width: 100%;
}


.email_input{
    position: relative;
    margin-top: 24px;
    background-color: #fff;
}



/*dashboard */



/* DASHBOARD GRID */
.dashboard-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr); /* 2 buttons per row */
  gap: 24px;
  margin-bottom: 32px;
}

/* SHELF BUTTON */
.dashboard-shelf {
  position: relative;
  height: 120px;                 /* SAME SIZE ALWAYS */
  border-radius: 16px;
  padding: 20px;
  cursor: pointer;
  overflow: hidden;

  display: flex;
  align-items: center;
  justify-content: space-between;

  box-shadow: 0 10px 30px rgba(0,0,0,0.08);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

/* Hover */
.dashboard-shelf:hover {
  transform: translateY(-4px);
  box-shadow: 0 14px 36px rgba(0,0,0,0.12);
}

/* TEXT */
.shelf-text {
  font-size: 1.2rem;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;

  transition: transform 0.3s ease;
}

/* ACTION BUTTONS (hidden by default) */
.shelf-actions {
  display: none; /* Hidden by default */
  opacity: 0;
  transition: opacity 0.3s ease;
  gap: 8px;
}

/* SHOW ACTIONS ON LONG PRESS */
.dashboard-shelf.active .shelf-text {
  transform: translateX(-20px);
}

.dashboard-shelf.active .shelf-actions {
  display: flex; /* Show on long press */
  opacity: 1;
}

/* ACTION BUTTON STYLE */
.rename-btn,
.delete-btn {
  background: #eaf6e8;
  border: none;
  border-radius: 8px;
  padding: 8px 10px;
  cursor: pointer;
  font-size: 0.9rem;
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.rename-btn:hover {
  background: #eaf6e8;
}

.delete-btn:hover {
  background: #eaf6e8;
}


/* FOOTER */
.footer {
  background: linear-gradient(180deg, #e8f4e1, #dcefd7);
  color: #1f2937;
  margin-top: 60px;
  padding-top: 40px;
  padding-bottom: 20px;
  border-top: 2px solid #7bbf4a;
}

.footer-container {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 30px;
  padding: 0 20px 40px 20px;
}

.footer-section h4 {
  color: #4b8f29;
  font-size: 1rem;
  margin-bottom: 12px;
  font-weight: 600;
}

.footer-section p {
  color: #6b7280;
  font-size: 0.9rem;
  line-height: 1.6;
}

.footer-section ul {
  list-style: none;
}

.footer-section ul li {
  margin-bottom: 8px;
}

.footer-section ul li a {
  color: #4b8f29;
  text-decoration: none;
  font-size: 0.9rem;
  transition: color 0.3s ease;
}

.footer-section ul li a:hover {
  color: #7bbf4a;
  text-decoration: underline;
}

.footer-bottom {
  text-align: center;
  padding-top: 20px;
  border-top: 1px solid rgba(123, 191, 74, 0.3);
  color: #6b7280;
  font-size: 0.85rem;
}


@media (max-width: 768px) {
  .footer-container {
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
  }
  
  .footer-section {
    padding: 15px;
  }
  
  .footer-section h4 {
    font-size: 14px;
    margin-bottom: 10px;
  }
  
  .footer-section p,
  .footer-section a {
    font-size: 12px;
  }
}

@media (max-width: 480px) {
  .footer-container {
    grid-template-columns: 1fr;
  }
  
  .footer-section {
    padding: 10px;
  }
}


/* RESPONSIVE */
@media (max-width: 700px) {
  .dashboard-grid {
    grid-template-columns: 1fr;
  }

  .footer-container {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .form-row {
    grid-template-columns: 1fr;
  }
}

/* BOOK FORM */
.book-form-container {
  max-width: 800px;
  margin: 40px auto;
  padding: 0 20px;
}

.book-form {
  background: #f1fbf6;
  padding: 30px;
  border-radius: 12px;
  border: 2px solid #9fd3b5;
}

.form-group {
  margin-bottom: 20px;
}

.form-group label {
  display: block;
  margin-bottom: 8px;
  font-weight: 600;
  color: #4b8f29;
  font-size: 0.95rem;
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 12px 16px;
  border: 2px solid #9fd3b5;
  border-radius: 8px;
  background: white;
  color: #1f2937;
  font-size: 0.95rem;
  font-family: inherit;
  transition: all 0.3s ease;
}

@media (max-width: 768px) {
  .form-group {
    margin-bottom: 15px;
  }
  
  .form-group label {
    font-size: 14px;
  }
  
  .form-group input,
  .form-group textarea {
    padding: 10px;
    font-size: 16px; /* Important for mobile! */
  }
}

@media (max-width: 480px) {
  .form-group {
    margin-bottom: 12px;
  }
  
  .form-group label {
    font-size: 13px;
  }
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: #7bbf4a;
  box-shadow: 0 0 8px rgba(123, 191, 74, 0.2);
  background: #ffffff;
}

.form-group textarea {
  resize: vertical;
  min-height: 100px;
}

.form-group input[readonly] {
  background: #e6f6ee;
  color: #6b7280;
  cursor: not-allowed;
}

.form-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 20px;
}

@media (max-width: 1024px) {
  .form-row {
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
  }
}

@media (max-width: 768px) {
  .form-row {
    grid-template-columns: 1fr;
    gap: 15px;
  }
}

.file-info,
.link-info {
  margin-top: 10px;
  font-size: 0.9rem;
  color: #4b8f29;
}

.file-info a,
.link-info a {
  color: #7bbf4a;
  text-decoration: none;
  font-weight: 500;
}

.file-info a:hover,
.link-info a:hover {
  text-decoration: underline;
}

/* COLLECTION TABLE */
.collection-container {
  max-width: 1200px;
  margin: 40px auto;
  padding: 0 20px 60px;
  overflow-x: auto;
}

.collection-section {
  margin-bottom: 50px;
}

.section-title {
  font-size: 1.5rem;
  font-weight: 600;
  color: #4b8f29;
  margin-bottom: 20px;
  padding-bottom: 12px;
  border-bottom: 3px solid #7bbf4a;
}

.collection-table {
  width: 100%;
  border-collapse: collapse;
  background: white;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
  border-radius: 8px;
  overflow: hidden;
}

.collection-table thead {
  background: linear-gradient(135deg, #7bbf4a, #5a9a2f);
  color: white;
}

.collection-table th {
  padding: 16px;
  text-align: left;
  font-weight: 600;
  border: none;
}

.collection-table tbody tr {
  border-bottom: 1px solid #e5e7eb;
  transition: background-color 0.2s ease;
}

.collection-table tbody tr:hover {
  background-color: #f9fef7;
}

.collection-table td {
  padding: 14px 16px;
  color: #1f2937;
  border: none;
}

.collection-table strong {
  color: #4b8f29;
  font-weight: 600;
}

.progress-bar {
  width: 100%;
  height: 8px;
  background-color: #e5e7eb;
  border-radius: 4px;
  overflow: hidden;
  margin-bottom: 4px;
}

.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, #7bbf4a, #5a9a2f);
  border-radius: 4px;
  transition: width 0.3s ease;
}

.progress-text {
  font-size: 0.85rem;
  color: #4b8f29;
  font-weight: 600;
}

.table-link {
  color: #7bbf4a;
  text-decoration: none;
  font-weight: 500;
  transition: color 0.2s ease;
}

.table-link:hover {
  color: #5a9a2f;
  text-decoration: underline;
}

.no-data {
  text-align: center;
  color: #6b7280;
  font-style: italic;
  padding: 30px 16px;
}

/* FORM ACTIONS */
.form-actions {
  display: flex;
  gap: 12px;
  margin-top: 30px;
  flex-wrap: wrap;
}

.form-actions button {
  flex: 1;
  min-width: 150px;
}

.active-btn {
  padding: 14px 28px;
  border-radius: 12px;
  border: none;
  background: linear-gradient(135deg, #5a9a2f, #4b8f29);
  color: white;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 4px 12px rgba(75, 143, 41, 0.3);
}

.active-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(75, 143, 41, 0.4);
  background: linear-gradient(135deg, #4b8f29, #3a7a1f);
}



 /*timer */

 /* READING TIMER PANEL */
.reading-timer {
  position: fixed;
  top: 140px;
  right: 40px;
  width: 260px;

  background: #ffffff;
  border-radius: 16px;
  padding: 24px;

  box-shadow: 0 12px 30px rgba(0,0,0,0.1);
  border: 2px solid #eaf6e8;
  z-index: 100;
}

.reading-timer h2 {
  text-align: center;
  font-size: 1.2rem;
  font-weight: 600;
  color: #4b8f29;
  margin-bottom: 16px;
}

/* TIMER DISPLAY */
.timer-display {
  font-size: 2.6rem;
  font-weight: 700;
  text-align: center;
  color: #1f2937;
  margin-bottom: 20px;
}

/* INPUT */
.timer-input {
  margin-bottom: 20px;
}

.timer-input label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  color: #4b8f29;
  margin-bottom: 6px;
}

.timer-input input {
  width: 100%;
  padding: 10px;
  border-radius: 8px;
  border: 2px solid #9fd3b5;
  font-size: 1rem;
}

/* CONTROLS */
.timer-controls {
  display: flex;
  gap: 10px;
}

.timer-controls button {
  flex: 1;
  padding: 10px;
  border-radius: 10px;
  border: none;
  cursor: pointer;
  font-weight: 600;
  font-size: 0.9rem;
}

/* BUTTON COLORS */
#startTimer {
  background: #7bbf4a;
  color: white;
}

#pauseTimer {
  background: #facc15;
  color: #1f2937;
}

#resetTimer {
  background: #ef4444;
  color: white;
}

/* MOBILE: hide timer */
@media (max-width: 900px) {
  .reading-timer {
    display: none;
  }
}



/* DAILY GOALS WITH FIXED HEIGHT */
.daily-goals-box {
  position: fixed;
  top: 130px;
  right: 40px;
  width: 500px;
  background: rgba(255, 255, 255, 0.98);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-radius: 24px;
  padding: 0; /* Remove padding from container */
  box-shadow: 
    0 20px 60px rgba(75, 143, 41, 0.1),
    0 8px 20px rgba(0, 0, 0, 0.05),
    inset 0 1px 0 rgba(255, 255, 255, 0.6);
  border: 1px solid rgba(234, 246, 232, 0.3);
  z-index: 100;
  display: flex;
  flex-direction: column;
  height: calc(100vh - 200px); /* Fixed height based on viewport */
  max-height: 700px;
  overflow: hidden; /* Hide overflow from container */
}

/* Header fixed at top */
.daily-goals-header {
  padding: 24px 28px 20px;
  border-bottom: 1px solid rgba(234, 246, 232, 0.5);
  flex-shrink: 0; /* Don't shrink */
}

.daily-goals-header h2 {
  color: #4b8f29;
  font-size: 24px;
  font-weight: 700;
  margin: 0;
  display: flex;
  align-items: center;
  gap: 10px;
}

/* Scrollable goals container */
.goals-scroll-container {
  flex: 1; /* Takes remaining space */
  overflow-y: auto;
  padding: 0 28px;
  max-height: calc(100% - 280px); /* Leaves space for strike counter */
}

/* Strike counter fixed at bottom */
.strike-counter-container {
  padding: 24px 28px;
  border-top: 1px solid rgba(234, 246, 232, 0.5);
  background: rgba(255, 255, 255, 0.9);
  flex-shrink: 0; /* Don't shrink */
  margin-top: auto; /* Push to bottom */
}

/* Custom scrollbar for goals */
.goals-scroll-container::-webkit-scrollbar {
  width: 6px;
}

.goals-scroll-container::-webkit-scrollbar-track {
  background: rgba(234, 246, 232, 0.2);
  border-radius: 10px;
  margin: 10px 0;
}

.goals-scroll-container::-webkit-scrollbar-thumb {
  background: rgba(75, 143, 41, 0.3);
  border-radius: 10px;
}

.goals-scroll-container::-webkit-scrollbar-thumb:hover {
  background: rgba(75, 143, 41, 0.5);
}

/* Compact table for many goals */
.daily-goals-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0 8px; /* Reduced spacing */
}

.daily-goals-table tbody tr {
  background: rgba(234, 246, 232, 0.4);
  border-radius: 12px;
  transition: all 0.2s ease;
  border: 1px solid rgba(234, 246, 232, 0.6);
}

.daily-goals-table tbody tr:hover {
  background: rgba(234, 246, 232, 0.6);
  transform: translateX(4px);
}

.daily-goals-table td {
  padding: 14px 16px; /* Reduced padding */
  border: none;
}

.daily-goals-table td:first-child {
  border-top-left-radius: 12px;
  border-bottom-left-radius: 12px;
  width: 40px; /* Reduced */
  padding-left: 20px;
}

.daily-goals-table td:last-child {
  border-top-right-radius: 12px;
  border-bottom-right-radius: 12px;
  padding-right: 20px;
}

/* Compact checkbox */
.goal-checkbox {
  width: 20px;
  height: 20px;
  border-radius: 6px;
}

/* Completed goal strikethrough styling */
.goal-item.completed-goal .goal-title {
  text-decoration: line-through;
  opacity: 0.6;
  color: #888;
}

.goal-item.completed-goal .goal-pages {
  opacity: 0.6;
  color: #888;
}

/* Truncate long book titles */
.daily-goals-table td:nth-child(2) {
  max-width: 150px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-size: 14px;
}

/* Compact strike counter */
.strike-counter {
  margin: 0;
}

.streak-stats {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
  margin-bottom: 16px;
}

.streak-item {
  background: rgba(234, 246, 232, 0.5);
  padding: 12px;
  border-radius: 10px;
  text-align: center;
}

.today-progress {
  margin-top: 12px;
}

/* Empty state with scrolling */
.empty-goals-scroll {
  height: 200px;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Responsive */
@media (max-height: 800px) {
  .daily-goals-box {
    height: calc(100vh - 180px);
    max-height: 500px;
  }
  
  .daily-goals-table td {
    padding: 10px 12px;
  }
}

@media (max-height: 600px) {
  .daily-goals-box {
    height: calc(100vh - 160px);
    max-height: 400px;
  }
  
  .daily-goals-header {
    padding: 16px 20px;
  }
  
  .strike-counter-container {
    padding: 16px 20px;
  }
  
  .goals-scroll-container {
    padding: 0 20px;
  }
}
























/* Analytical ring styles */

/* Container */

.progress-rings-container {
  position: relative;
  left: 0;
  margin-right: auto; /* Push to left */
  margin-left: 0;
  align-self: flex-start; /* Align to start of flex container */
}

/* Rings Wrapper */
.rings-wrapper {
  position: relative;
  width: 400px;
  height: 400px;
}

/* Base Ring Styles */
.ring {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}

.ring-svg {
  width: 100%;
  height: 100%;
  transform: rotate(-90deg); /* Start from top */
}

.ring-background {
  fill: none;
  stroke: #f1f5f9;
  stroke-width: 8;
}

.ring-progress {
  fill: none;
  stroke-linecap: round;
  transition: stroke-dashoffset 1s ease-in-out;
}


.monthly-ring .ring-label {
  position: absolute;
  top: -30px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 12px;
  color: #0ea5e9;
  font-weight: 600;
  white-space: nowrap;
}


.yearly-ring .ring-label {
  position: absolute;
  top: -30px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 12px;
  color: #b325e7;
  font-weight: 600;
  white-space: nowrap;
}


/* monthly Ring (Middle, medium) */
.monthly-ring, yearly-ring {
  width: 280px;
  height: 280px;
}

.monthly .ring-background , yearly .ring-background {
  stroke-width: 10; /* Medium */
  stroke: #dcfce7; /* Light green */
}

.monthly-ring .ring-progress, yearly-ring .ring-progress {
  stroke-width: 10;
  stroke: #10b981; /* Green */
}



/* Center Stats */
.center-stats {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  text-align: center;
  z-index: 10;
  background: white;
  padding: 30px;
  border-radius: 50%;
  width: 180px;
  height: 180px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.stat-books, .stat-pages {
  margin: 10px 0;
}

.stat-icon {
  font-size: 24px;
  margin-bottom: 5px;
}

.stat-value {
  font-size: 28px;
  font-weight: 800;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  line-height: 1;
}

.stat-label {
  font-size: 12px;
  color: #64748b;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-top: 2px;
}

/* Legend */
.rings-legend {
  display: flex;
  justify-content: center;
  gap: 30px;
  margin-top: 40px;
  flex-wrap: wrap;
}

.legend-item {
  display: flex;
  align-items: center;
  gap: 8px;
}

.legend-color {
  width: 16px;
  height: 16px;
  border-radius: 50%;
}



.monthly-color {
  background: #10b981;
  box-shadow: 0 0 0 6px #dcfce7;
}

.yearly-color {
  background: #b325e7;
  box-shadow: 0 0 0 6px #dcfce7;
}



.legend-text {
  font-size: 14px;
  color: #475569;
  font-weight: 500;
}

/* Hover Effects */
.ring:hover .ring-progress {
  stroke-width: calc(var(--base-width) + 2);
  filter: brightness(1.1);
}

.center-stats:hover {
  transform: translate(-50%, -50%) scale(1.05);
  transition: transform 0.3s ease;
}

/* Reading Statistics Chart Styles */
.reading-stats-section {
  background: white;
  border-radius: 16px;
  padding: 24px;
  margin: 20px 24px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.reading-stats-section h2 {
  color: #1f2937;
  font-size: 20px;
  font-weight: 600;
  margin-bottom: 20px;
  text-align: center;
}

.chart-container {
  position: relative;
  width: 100%;
  max-width: 400px;
  margin: 0 auto 30px;
  aspect-ratio: 1;
}

#readingStatsChart {
  max-width: 100%;
}

.stats-labels {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 24px;
}

.stat-label {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  background: #f9fafb;
  border-radius: 8px;
  border-left: 4px solid;
}

.stat-label.completed {
  border-left-color: #4CAF50;
}

.stat-label.active {
  border-left-color: #2196F3;
}

.stat-label.unread {
  border-left-color: #BDBDBD;
}

.stat-color {
  width: 16px;
  height: 16px;
  border-radius: 4px;
  flex-shrink: 0;
}

.stat-text {
  font-size: 14px;
  color: #4b5563;
  flex: 1;
}

.stat-text strong {
  color: #1f2937;
  font-weight: 600;
}

.stats-details {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.stat-detail {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px;
  background: linear-gradient(135deg, #f0f9ff 0%, #f0fdf4 100%);
  border-radius: 8px;
  border: 1px solid #e5e7eb;
}

.detail-label {
  font-size: 13px;
  color: #6b7280;
  font-weight: 500;
}

.detail-value {
  font-size: 16px;
  font-weight: 600;
  color: #1f2937;
}

@media (max-width: 768px) {
  .chart-container {
    max-width: 300px;
  }
  
  .stats-details {
    grid-template-columns: 1fr;
  }
  
  .reading-stats-section {
    padding: 16px;
  }
}



/* ============================================
   MOBILE RESPONSIVE STYLES
   ============================================ */

/* Mobile First - Base styles for mobile */
@media (max-width: 768px) {
    /* Navbar */
    .navbar {
        padding: 12px 16px;
        flex-direction: row;
        justify-content: space-between;
    }
    
    .logo img {
        height: 50px;
    }
    
    .back-btn {
        padding: 6px 10px;
        font-size: 18px;
    }
    
    /* Hero */
    .headline {
        font-size: 1.8rem;
    }
    
    .subtitle {
        font-size: 0.95rem;
    }
    
    /* Shelf Grid - Single Column */
    .shelf-container {
        grid-template-columns: 1fr;
        padding: 0 16px;
        gap: 15px;
    }
    
    .dashboard-shelf {
        height: 80px;
        font-size: 1rem;
    }
    
    /* Stats Grid - 2 Columns */
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }
    
    /* Profile - Stack Vertically */
    .profile-content {
        grid-template-columns: 1fr;
    }
    
    .profile-header-content {
        flex-direction: column;
        text-align: center;
    }
    
    .profile-avatar-large {
        width: 80px;
        height: 80px;
        font-size: 36px;
    }
    
    /* Hide Sidebars on Mobile */
    .reading-timer,
    .yearly-leaderboard,
    .daily-goals-box {
        position: static;
        width: 100%;
        margin: 20px 0;
    }
    
    /* Forms */
    .create-form {
        flex-direction: column;
    }
    
    .create-form input {
        width: 100%;
    }
    
    /* Buttons */
    .btn {
        padding: 12px 20px;
        font-size: 14px;
        min-height: 44px; /* Touch-friendly */
    }
    
    /* Footer */
    .footer-container {
        grid-template-columns: 1fr;
        text-align: center;
    }
}

/* Tablet Styles */
@media (min-width: 769px) and (max-width: 1024px) {
    .shelf-container {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .stats-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}


/* Modal Styles */
  .modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
  }

  .modal-content {
    background: white;
    border-radius: 12px;
    padding: 0;
    width: 90%;
    max-width: 400px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
    animation: slideDown 0.3s ease;
  }

  @keyframes slideDown {
    from {
      transform: translateY(-50px);
      opacity: 0;
    }
    to {
      transform: translateY(0);
      opacity: 1;
    }
  }

  .modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    border-bottom: 1px solid #e0e0e0;
  }

  .modal-header h2 {
    margin: 0;
    font-size: 20px;
    color: #333;
  }

  .modal-close {
    background: none;
    border: none;
    font-size: 28px;
    cursor: pointer;
    color: #666;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
  }

  .modal-close:hover {
    color: #333;
  }

  .modal-body {
    padding: 20px;
  }

  .modal-body p {
    margin: 0 0 15px 0;
    color: #666;
    font-size: 14px;
  }

  .shelf-list {
    max-height: 300px;
    overflow-y: auto;
  }

  .shelf-option {
    padding: 12px 15px;
    border: 1px solid #ddd;
    border-radius: 8px;
    margin-bottom: 10px;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    justify-content: space-between;
    align-items: center;
  }

  .shelf-option:hover {
    background: #f5f5f5;
    border-color: #667eea;
    transform: translateX(5px);
  }

  .shelf-option.current {
    background: #e8f5e9;
    border-color: #4caf50;
  }

  .shelf-option.current::after {
    content: "✓";
    color: #4caf50;
    font-weight: bold;
    font-size: 18px;
  }

  .shelf-option-name {
    font-weight: 500;
    color: #333;
  }

  .shelf-option-count {
    font-size: 12px;
    color: #999;
  }









  /* Shelf View Button Styling */
.shelf-view-button-container {
    margin: 20px 0;
    text-align: center;
}

.shelf-view-btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 15px 40px;
    border-radius: 30px;
    text-decoration: none;
    font-weight: bold;
    font-size: 1.1em;
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
    cursor: pointer;
}

.shelf-view-btn:hover {
    transform: translateY(-4px) scale(1.05);
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.6);
    background: linear-gradient(135deg, #764ba2 0%, #667eea 100%);
}

.shelf-view-btn:active {
    transform: translateY(-2px);
}

.btn-icon {
    font-size: 1.3em;
}

.btn-text {
    letter-spacing: 0.5px;
}













@media (max-width: 768px) {
  .floating-widget {
    position: fixed;
    bottom: 10px !important;
    right: 10px !important;
    padding: 10px 15px !important;
    font-size: 12px !important;
  }
}

@media (max-width: 480px) {
  .floating-widget {
    bottom: 5px !important;
    right: 5px !important;
    padding: 8px 12px !important;
  }
  
  .floating-widget > div:first-child {
    width: 8px !important;
    height: 8px !important;
  }
}