@import url('https://fonts.googleapis.com/css2?family=Roboto:wght@300;400;500;700&display=swap');

/* إيقاف الوضع الداكن نهائيًا */
:root, html, body { color-scheme: light; }

:root{
  --primary-color: #bb7000;
  --primary-hover: #a86600;
  --primary-light: #d88a00;
  --text-color: #000000;
  --text-secondary: #f8f8f8;
  --border-color: #7e7e7e;
  --bg-light: #ffffff;
  --bg-card: #f8f8f8;
  --bg-overlay: rgba(255, 255, 255, 0.95);
  --transition-speed: .35s;
  --box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
  --box-shadow-hover: 0 12px 32px rgba(0, 0, 0, 0.18);
}

*{margin:0;padding:0;box-sizing:border-box}
html{font-size:63.5%;scroll-behavior:smooth;overflow-x:hidden;max-width:100vw}

/* Page Load Animation */
@keyframes fadeInUp{
  from{opacity:0;transform:translateY(30px)}
  to{opacity:1;transform:translateY(0)}
}
@keyframes fadeIn{
  from{opacity:0}
  to{opacity:1}
}
@keyframes slideInLeft{
  from{opacity:0;transform:translateX(-50px)}
  to{opacity:1;transform:translateX(0)}
}
@keyframes slideInRight{
  from{opacity:0;transform:translateX(50px)}
  to{opacity:1;transform:translateX(0)}
}

body{
  background-image:url("images/background.jpg");
  background-size:cover;
  background-repeat:no-repeat;
  background-position:center;
  background-attachment:fixed;
  font-family:"Roboto",sans-serif;
  color:var(--text-color);
  min-height:100vh;
  line-height:1.65;
  overflow-x:hidden;
  max-width:100vw;
}

.container{
  margin:0 auto;
  padding:0 2rem;
  width:100%;
  max-width:100%;
}

/* ===== Header ===== */
header{
  padding:2.5rem 0;
  display:flex;
  justify-content:space-between;
  align-items:center;
  background: rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(15px);
  border-radius: 2rem;
  padding: 1.5rem 2rem;
  margin: 2rem 0;
  box-shadow: 
    0 20px 40px rgba(0, 0, 0, 0.15),
    0 10px 20px rgba(0, 0, 0, 0.1),
    inset 0 1px 0 rgba(255, 255, 255, 0.5),
    inset 0 -1px 0 rgba(0, 0, 0, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.15);
  animation: fadeIn 0.6s ease-out;
  position: relative;
  width: 100%;
  max-width: 100%;
}
header::before{
  content: '';
  position: absolute;
  inset: -2px;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.15), transparent);
  border-radius: 2rem;
  z-index: -1;
  filter: blur(10px);
}

.left-section img{
  width:14rem;
  border:3px solid rgba(255, 255, 255, 0.3);
  border-radius:1.5rem;
  padding:.8rem;
  background: rgba(255, 255, 255, 0.95);
  box-shadow:0 6px 20px rgba(0, 0, 0, 0.15);
  transition:all var(--transition-speed) ease;
  animation: slideInLeft 0.8s ease-out;
  transform-style: preserve-3d;
}
.left-section img:hover{
  transform:scale(1.05) translateY(-5px) translateZ(10px);
  box-shadow:
    0 20px 40px rgba(0, 0, 0, 0.3), 
    0 10px 25px rgba(187, 112, 0, 0.4);
  border-color: var(--primary-color);
  filter: brightness(1.08) contrast(1.05);
}

.right-section{display:flex;gap:1rem;flex-wrap:wrap}
.right-section a{
  color:#000;font-size:1.8rem;font-weight:500;text-decoration:none;padding:1.2rem 2.5rem;border-radius:1.2rem;
  position:relative;overflow:hidden;background:rgba(255,255,255,.75);backdrop-filter:blur(8px);
  border:2px solid rgba(0,0,0,.08);transition:all var(--transition-speed) ease;text-shadow:none;
  animation:slideInRight .8s ease-out backwards;
  box-shadow:0 6px 15px rgba(0,0,0,.1),0 3px 8px rgba(0,0,0,.08),inset 0 1px 0 rgba(255,255,255,.8);
}
.right-section a:nth-child(1){animation-delay:.1s}
.right-section a:nth-child(2){animation-delay:.2s}
.right-section a:nth-child(3){animation-delay:.3s}
.right-section a:nth-child(4){animation-delay:.4s}
.right-section a::before{
  content:'';position:absolute;left:0;bottom:0;width:100%;height:100%;
  background:linear-gradient(135deg,var(--primary-color),var(--primary-light));
  transform:scaleX(0);transform-origin:left;transition:transform var(--transition-speed) ease;z-index:-1;
}
.right-section a:hover::before,
.right-section a.active::before{transform:scaleX(1)}
.right-section a:hover,
.right-section a.active{
  transform:translateY(-4px);
  box-shadow:0 12px 30px rgba(0,0,0,.2),0 6px 15px rgba(187,112,0,.3),inset 0 1px 0 rgba(255,255,255,.5);
  border-color:var(--primary-color);color:#fff;
}
.right-section a:focus{outline:3px solid var(--primary-color);outline-offset:3px}
.right-section a:active{
  transform:translateY(-2px);box-shadow:0 6px 15px rgba(0,0,0,.15),inset 0 2px 4px rgba(0,0,0,.15);
}

hr{
  height:2px;
  background: linear-gradient(90deg, transparent, var(--primary-color), transparent);
  border:none;
  margin:2rem 0;
  box-shadow:0 2px 8px rgba(0, 0, 0, 0.1);
  width:100%;
}

/* ===== Photo Container ===== */
.Photo {
    width: calc(100% - 4rem);
    max-width: 100%;
    border-radius: 2rem;
    border: 3px solid rgba(255, 255, 255, 0.3);
    margin: 2rem auto;
    padding: 1.5rem;
    background: rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(15px);
    box-shadow: 
        0 20px 40px rgba(0, 0, 0, 0.2),
        0 10px 20px rgba(0, 0, 0, 0.15),
        0 5px 10px rgba(187, 112, 0, 0.15),
        inset 0 2px 0 rgba(255, 255, 255, 0.3),
        inset 0 -2px 0 rgba(0, 0, 0, 0.1);
    position: relative;
    animation: fadeInUp 0.8s ease-out 0.2s backwards;
    display: block;
    overflow: hidden;
}

.Photo::before {
    content: '';
    position: absolute;
    inset: -3px;
    background: linear-gradient(135deg, rgba(187, 112, 0, 0.15), transparent, rgba(187, 112, 0, 0.08));
    border-radius: 2rem;
    z-index: -1;
    filter: blur(15px);
}

.Photo::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.05), transparent);
    border-radius: 2rem;
    pointer-events: none;
}

.Photo img {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 1rem;
    object-fit: cover;
    transition: transform var(--transition-speed) ease, filter var(--transition-speed) ease;
}

.Photo:hover img {
    transform: scale(1.01);
    filter: brightness(1.02) contrast(1.01);
}

/* ===== PDF Wrapper ===== */
.Data{
  position:relative;
  display:flex;
  flex-direction:column;
  gap:1.5rem;
  justify-content:center;
  align-items:stretch;
  min-height:100vh;
  background: rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(15px);
  border: 2px solid rgba(255, 255, 255, 0.2);
  box-shadow: 
    0 30px 60px rgba(0, 0, 0, 0.25),
    0 15px 30px rgba(0, 0, 0, 0.15),
    0 5px 15px rgba(0, 0, 0, 0.1),
    inset 0 2px 0 rgba(255, 255, 255, 0.3),
    inset 0 -2px 0 rgba(0, 0, 0, 0.1);
  border-radius:2.5rem;
  margin:3rem 2rem;
  padding:2rem;
  animation: fadeInUp 0.8s ease-out 0.3s backwards;
}
.Data::before{
  content: '';
  position: absolute;
  inset: -3px;
  background: linear-gradient(135deg, rgba(187, 112, 0, 0.15), transparent, rgba(187, 112, 0, 0.08));
  border-radius: 2.5rem;
  z-index: -1;
  filter: blur(15px);
}
.Data::after{
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.05), transparent);
  border-radius: 2.5rem;
  pointer-events: none;
}

.pdf-header{
  width:100%;
  box-shadow: 
    0 15px 35px rgba(187, 112, 0, 0.4),
    0 8px 20px rgba(187, 112, 0, 0.3),
    0 3px 10px rgba(187, 112, 0, 0.2),
    inset 0 2px 0 rgba(255, 255, 255, 0.3),
    inset 0 -2px 0 rgba(0, 0, 0, 0.2);
  border-radius:1.5rem;
  padding:2rem;
  text-align:center;
  margin-bottom:1rem;
  border: 2px solid rgba(255, 255, 255, 0.2);
  position: relative;
  overflow: hidden;
}
.pdf-header::before{
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: linear-gradient(45deg, transparent, rgba(255, 255, 255, 0.1), transparent);
  transform: rotate(45deg);
  animation: shine 3s infinite;
}
@keyframes shine{
  0%{transform: translateX(-100%) translateY(-100%) rotate(45deg)}
  100%{transform: translateX(100%) translateY(100%) rotate(45deg)}
}

/* ===== PDF Tabs Styling ===== */
.pdf-tabs{
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  justify-content: center;
  margin-bottom: 1.5rem;
}

.pdf-tab{
  cursor: pointer;
  padding: 1.2rem 2.5rem;
  border-radius: 1.2rem;
  font-size: 1.7rem;
  font-weight: 600;
  color: var(--text-color);
  background: rgba(255, 255, 255, 0.75);
  backdrop-filter: blur(8px);
  border: 2px solid rgba(187, 112, 0, 0.3);
  transition: all var(--transition-speed) ease;
  box-shadow: 0 6px 15px rgba(0, 0, 0, 0.1);
  position: relative;
  overflow: hidden;
  z-index: 1;
}

.pdf-tab::before{
  content: '';
  position: absolute;
  left: 0;
  bottom: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, var(--primary-color), var(--primary-light));
  transform: scaleX(0);
  transform-origin: left;
  transition: transform var(--transition-speed) ease;
  z-index: -1;
}

.pdf-tab:hover::before,
.pdf-tab.active::before{
  transform: scaleX(1);
}

.pdf-tab:hover,
.pdf-tab.active{
  color: #fff;
  border-color: var(--primary-color);
  transform: translateY(-4px);
  box-shadow: 
    0 12px 30px rgba(187, 112, 0, 0.4),
    0 6px 15px rgba(187, 112, 0, 0.3);
}

.pdf-tab:active{
  transform: translateY(-2px);
}

/* ===== Toolbar ===== */
.pdf-controls{
  width:100%;
  display:flex;
  align-items:center;
  justify-content:space-between;
  flex-wrap:wrap;
  gap:1.5rem;
  padding:1.2rem 1.5rem;
  border-radius:1.5rem;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.85), rgba(248, 248, 248, 0.85));
  backdrop-filter: blur(15px);
  box-shadow: 
    0 12px 30px rgba(0, 0, 0, 0.15),
    0 6px 15px rgba(0, 0, 0, 0.1),
    0 2px 8px rgba(187, 112, 0, 0.15),
    inset 0 1px 0 rgba(255, 255, 255, 0.8),
    inset 0 -1px 0 rgba(0, 0, 0, 0.05);
  border: 2px solid rgba(187, 112, 0, 0.2);
  position: relative;
}
.pdf-controls::before{
  content: '';
  position: absolute;
  inset: -2px;
  background: linear-gradient(135deg, rgba(187, 112, 0, 0.1), transparent);
  border-radius: 1.5rem;
  z-index: -1;
  filter: blur(8px);
}
.pdf-controls .left-group{
  display:flex;
  align-items:center;
  gap:1.2rem;
  flex-wrap: wrap;
}
.pdf-controls .right-group{
  display:flex;
  align-items:center;
  gap:1rem;
  flex-wrap:wrap;
}

#pageIndicator{
  font-size: 1.6rem;
  font-weight: 600;
  color: var(--text-color);
  padding: 1rem 1.8rem;
  background: linear-gradient(135deg, rgba(187, 112, 0, 0.15), rgba(187, 112, 0, 0.08));
  border-radius: 1rem;
  border: 2px solid rgba(187, 112, 0, 0.3);
  box-shadow: 
    0 6px 18px rgba(187, 112, 0, 0.2),
    0 3px 10px rgba(187, 112, 0, 0.15),
    inset 0 1px 0 rgba(255, 255, 255, 0.6);
  transition: all 0.3s ease;
  white-space: nowrap;
}
#pageIndicator:hover{
  transform: translateY(-2px);
  box-shadow: 
    0 8px 24px rgba(187, 112, 0, 0.3),
    0 4px 12px rgba(187, 112, 0, 0.2);
}

.pdf-controls button{
  cursor:pointer;
  border:2px solid var(--primary-color);
  background: linear-gradient(135deg, var(--primary-color), var(--primary-light));
  color:var(--text-secondary);
  padding:1rem 1.8rem;
  border-radius:1rem;
  font-size:1.6rem;
  font-weight:500;
  transition:all var(--transition-speed) ease;
  box-shadow: 
    0 8px 20px rgba(187, 112, 0, 0.35),
    0 4px 10px rgba(187, 112, 0, 0.25),
    inset 0 1px 0 rgba(255, 255, 255, 0.4),
    inset 0 -2px 0 rgba(0, 0, 0, 0.15);
  position: relative;
  overflow: hidden;
  white-space: nowrap;
}
.pdf-controls button::before{
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.3);
  transform: translate(-50%, -50%);
  transition: width 0.5s, height 0.5s;
}
.pdf-controls button:hover::before{
  width: 300px;
  height: 300px;
}
.pdf-controls button:hover{
  background: linear-gradient(135deg, var(--primary-hover), var(--primary-color));
  transform:translateY(-3px) scale(1.02);
  box-shadow: 
    0 12px 30px rgba(187, 112, 0, 0.5), 
    0 6px 15px rgba(187, 112, 0, 0.35),
    0 0 25px rgba(187, 112, 0, 0.3),
    inset 0 1px 0 rgba(255, 255, 255, 0.5);
}
.pdf-controls button:active{
  transform:translateY(-1px) scale(0.98);
  box-shadow: 
    0 4px 12px rgba(187, 112, 0, 0.4),
    inset 0 2px 4px rgba(0, 0, 0, 0.2);
}
.pdf-controls button:focus{
  outline: 3px solid var(--primary-color);
  outline-offset: 3px;
}
.pdf-controls button:disabled{
  opacity:.5;
  cursor:not-allowed;
  transform:none;
  background: linear-gradient(135deg, #ccc, #999);
  border-color: #999;
  box-shadow: none;
}

.zoom-select select{
  height:44px;
  min-width:100px;
  padding:.5rem 1.2rem;
  border-radius:1rem;
  border:2px solid var(--primary-color);
  background: rgba(255, 255, 255, 0.95);
  color:var(--text-color);
  font-size:1.6rem;
  font-weight:500;
  cursor: pointer;
  transition: all var(--transition-speed) ease;
  box-shadow: 0 4px 12px rgba(187, 112, 0, 0.2);
}
.zoom-select select:hover{
  border-color: var(--primary-hover);
  box-shadow: 0 6px 16px rgba(187, 112, 0, 0.3);
  transform: translateY(-1px);
}
.zoom-select select:focus{
  outline: 3px solid var(--primary-color);
  outline-offset: 3px;
  border-color: var(--primary-hover);
  box-shadow: 0 0 0 3px rgba(187, 112, 0, 0.2);
}

/* ===== Loader ===== */
.loader{
  position:absolute;
  inset:0;
  display:flex;
  align-items:center;
  justify-content:center;
  background: rgba(255, 255, 255, 0.98);
  backdrop-filter: blur(10px);
  border-radius:2rem;
  z-index:10;
  flex-direction: column;
  gap: 2rem;
}
.loader-text{
  font-size: 2rem;
  font-weight: 600;
  color: var(--primary-color);
  animation: pulse 1.5s ease-in-out infinite;
  text-shadow: 0 2px 4px rgba(187, 112, 0, 0.2);
}
@keyframes pulse{
  0%, 100%{opacity: 1; transform: scale(1)}
  50%{opacity: 0.7; transform: scale(0.98)}
}
.loader::after{
  content:"";
  width:70px;
  height:70px;
  border:7px solid rgba(187, 112, 0, 0.2);
  border-top-color:var(--primary-color);
  border-right-color:var(--primary-color);
  border-radius:50%;
  animation:spin .8s linear infinite;
  box-shadow: 0 4px 12px rgba(187, 112, 0, 0.3);
}
@keyframes spin{to{transform:rotate(360deg)}}

/* ===== PDF Canvas Container ===== */
.Pdf{
  width:100%;
  height:90vh;
  border-radius:2rem;
  border:3px solid var(--primary-color);
  margin-top:1rem;
  position:relative;
  overflow:auto;
  background: transparent;
  display:block;
  padding:0;
  user-select:none;
  -webkit-user-drag:none;
  align-content:center;
  touch-action: pan-x pan-y;
  -webkit-overflow-scrolling: touch;
  box-shadow: inset 0 4px 12px rgba(0, 0, 0, 0.1);
  cursor: grab;
}
.Pdf.dragging{
  cursor: grabbing;
}
canvas{
  display:block;
  image-rendering:auto;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
}

/* ===== Drawer Sidebar (Thumbnails) ===== */
.thumb-drawer[hidden]{display:none}
.thumb-drawer{
  position:fixed;
  top:0;
  left:0;
  height:100dvh;
  width:320px;
  max-width:85vw;
  background: linear-gradient(135deg, #2d2d2d, #1a1a1a);
  border-right:3px solid var(--primary-color);
  box-shadow:8px 0 32px rgba(0, 0, 0, 0.4);
  z-index:9998;
  display:grid;
  grid-template-rows:auto 1fr;
  transform:translateX(-110%);
  opacity:0;
  transition:transform .4s cubic-bezier(0.4, 0, 0.2, 1), opacity .4s ease;
}
.thumb-drawer.open{
  transform:translateX(0);
  opacity:1;
}

.drawer-head{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:1rem;
  padding:1.5rem 1.5rem;
  border-bottom:2px solid var(--primary-color);
  background: linear-gradient(135deg, var(--primary-color), var(--primary-light));
  color:var(--text-secondary);
  font-size: 1.8rem;
  font-weight: 600;
}
.drawer-head button{
  background: rgba(255, 255, 255, 0.2);
  border: 2px solid rgba(255, 255, 255, 0.3);
  color: #ffffff;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 1.8rem;
  font-weight: bold;
}
.drawer-head button:hover{
  background: rgba(255, 255, 255, 0.4);
  transform: rotate(90deg);
}

.drawer-list{
  overflow-y: auto;
  padding: 1.5rem;
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
  -webkit-overflow-scrolling: touch;
}

.thumb-item{
  position: relative;
  cursor: pointer;
  border-radius: 1rem;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.05);
  border: 2px solid rgba(255, 255, 255, 0.1);
  transition: all 0.3s ease;
  min-height: 180px;
}
.thumb-item:hover{
  border-color: var(--primary-color);
  box-shadow: 0 8px 20px rgba(187, 112, 0, 0.4);
  transform: translateY(-3px);
}
.thumb-item.active{
  border-color: var(--primary-color);
  box-shadow: 0 0 20px rgba(187, 112, 0, 0.6);
}

.thumb-num{
  position: absolute;
  top: 0.8rem;
  left: 0.8rem;
  background: var(--primary-color);
  color: white;
  padding: 0.5rem 1rem;
  border-radius: 0.6rem;
  font-size: 1.4rem;
  font-weight: 600;
  z-index: 2;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.thumb-skeleton{
  width: 100%;
  min-height: 180px;
  aspect-ratio: 0.707;
  background: linear-gradient(90deg, #2d2d2d 25%, #3d3d3d 50%, #2d2d2d 75%);
  background-size: 200% 100%;
  animation: skeleton-loading 1.5s infinite;
}
@keyframes skeleton-loading{
  0%{background-position: 200% 0}
  100%{background-position: -200% 0}
}

.thumb-item canvas{
  width: 100%;
  min-height: 180px;
  height: auto;
  display: block;
}

.drawer-backdrop[hidden]{display:none}
.drawer-backdrop{
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  z-index: 9997;
  backdrop-filter: blur(3px);
  animation: fadeIn 0.3s ease-out;
}

/* ===== Fullscreen Bar ===== */
.fs-inline-bar{
  position: fixed;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.95), rgba(248, 248, 248, 0.95));
  backdrop-filter: blur(15px);
  border-radius: 1.5rem;
  padding: 1.2rem 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  box-shadow: 
    0 12px 30px rgba(0, 0, 0, 0.25),
    0 6px 15px rgba(0, 0, 0, 0.15),
    inset 0 1px 0 rgba(255, 255, 255, 0.8);
  border: 2px solid rgba(187, 112, 0, 0.3);
  z-index: 100000;
  max-width: 95%;
  flex-wrap: wrap;
}

.fs-inline-indicator{
  font-size: 1.6rem;
  font-weight: 600;
  color: var(--text-color);
  padding: 0.8rem 1.5rem;
  background: linear-gradient(135deg, rgba(187, 112, 0, 0.15), rgba(187, 112, 0, 0.08));
  border-radius: 1rem;
  border: 2px solid rgba(187, 112, 0, 0.3);
  white-space: nowrap;
}

.fs-inline-btns{
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.fs-inline-btn{
  cursor: pointer;
  border: 2px solid var(--primary-color);
  background: linear-gradient(135deg, var(--primary-color), var(--primary-light));
  color: var(--text-secondary);
  padding: 0.8rem 1.5rem;
  border-radius: 1rem;
  font-size: 1.5rem;
  font-weight: 500;
  transition: all var(--transition-speed) ease;
  box-shadow: 0 6px 15px rgba(187, 112, 0, 0.3);
  white-space: nowrap;
}
.fs-inline-btn:hover{
  background: linear-gradient(135deg, var(--primary-hover), var(--primary-color));
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(187, 112, 0, 0.4);
}
.fs-inline-btn:active{
  transform: translateY(-1px);
}

.fs-inline-zoom{
  height: 38px;
  min-width: 90px;
  padding: 0.5rem 1rem;
  border-radius: 1rem;
  border: 2px solid var(--primary-color);
  background: rgba(255, 255, 255, 0.95);
  color: var(--text-color);
  font-size: 1.5rem;
  font-weight: 500;
  cursor: pointer;
  transition: all var(--transition-speed) ease;
}
.fs-inline-zoom:hover{
  border-color: var(--primary-hover);
  box-shadow: 0 4px 12px rgba(187, 112, 0, 0.3);
}

/* ===== Folder Data Container ===== */
.Folder-Data {
  width: 100%;
  margin: 3rem 0;
  padding: 3rem;
  background: rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(15px);
  border-radius: 2rem;
  box-shadow: 
    0 20px 40px rgba(0, 0, 0, 0.15),
    0 10px 20px rgba(0, 0, 0, 0.1),
    inset 0 1px 0 rgba(255, 255, 255, 0.5),
    inset 0 -1px 0 rgba(0, 0, 0, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.15);
  animation: fadeInUp 0.8s ease-out 0.4s backwards;
  position: relative;
  overflow: visible;
}
.Folder-Data::before{
  content: '';
  position: absolute;
  inset: -2px;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.15), transparent);
  border-radius: 2rem;
  z-index: -1;
  filter: blur(10px);
}

.Files {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(30rem, 1fr));
  gap: 2rem;
  width: 100%;
}

.utility-item {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  padding: 2rem;
  background: rgba(255, 255, 255, 0.75);
  backdrop-filter: blur(10px);
  border: 2px solid rgba(0, 0, 0, 0.08);
  border-radius: 1.5rem;
  cursor: pointer;
  transition: all 0.4s ease;
  box-shadow: 0 6px 15px rgba(0, 0, 0, 0.1), 0 3px 8px rgba(0, 0, 0, 0.08), inset 0 1px 0 rgba(255, 255, 255, 0.8);
}
.utility-item:hover {
  background: linear-gradient(135deg, var(--primary-color), var(--primary-light));
  border-color: var(--primary-color);
  transform: translateY(-5px);
  box-shadow: 
    0 12px 30px rgba(0, 0, 0, 0.2),
    0 6px 15px rgba(187, 112, 0, 0.3),
    inset 0 1px 0 rgba(255, 255, 255, 0.5);
}
.folder-icon {
  font-size: 4rem;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.2));
  transition: transform 0.3s ease;
}
.utility-item:hover .folder-icon {
  transform: scale(1.1) rotate(5deg);
}
.utility-item span {
  color: #000;
  font-size: 1.8rem;
  font-weight: 500;
  text-shadow: none;
  flex: 1;
  transition: color 0.3s ease;
}
.utility-item:hover span {
  color: #fff;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

::-webkit-scrollbar{width:6px;height:6px}
::-webkit-scrollbar-track{background:rgba(0,0,0,.05);border-radius:5px}
::-webkit-scrollbar-thumb{
  background:linear-gradient(135deg,var(--primary-color),var(--primary-light));
  border-radius:5px;border:1px solid rgba(255,255,255,.1);transition:all .3s ease;
}
::-webkit-scrollbar-thumb:hover{
  background:linear-gradient(135deg,var(--primary-light),var(--primary-hover));
  box-shadow:0 0 10px rgba(187,112,0,.5);
}

img, video, iframe {
  max-width: 100%;
  height: auto;
}

/* ===== Responsive - Starting from Largest to Smallest ===== */

/* Large Desktop (1200px+) - Default styles above */

/* Medium Desktop (992px - 1199px) */
@media (max-width: 1199px) {
  html {font-size: 62.5%}
}

/* Tablet Landscape / Small Desktop (768px - 991px) */
@media (max-width: 992px) {
  html {font-size: 62%}
  
  .Photo {
    width: calc(100% - 3rem);
    margin: 1.8rem auto;
    padding: 1.3rem;
  }
  
  .Photo img {
    border-radius: 0.9rem;
  }
  
  .pdf-controls{
    justify-content: center;
  }
  
  .pdf-controls .left-group{
    justify-content: center;
  }
  
  .pdf-controls .right-group{
    justify-content: center;
  }
  
  .Files {
    grid-template-columns: repeat(auto-fit, minmax(25rem, 1fr));
  }
}

/* Tablet Portrait (768px - 991px) */
@media (max-width: 768px) {
  html {font-size: 60%}
  
  header {
    flex-direction: column;
    padding: 1.5rem;
  }
  
  .right-section {
    flex-wrap: wrap;
    justify-content: center;
  }
  
  .Photo {
    width: calc(100% - 3rem);
    margin: 1.5rem auto;
    border-width: 2px;
    padding: 1.2rem;
  }
  
  .Photo img {
    border-radius: 0.9rem;
  }
  
  .Data, .Folder-Data{
    margin: 2rem 1rem;
    padding: 1.5rem;
  }
  
  .pdf-header{
    padding: 1.5rem;
  }
  
  .pdf-tabs{
    gap: 0.8rem;
  }
  
  .pdf-tab{
    padding: 1rem 1.8rem;
    font-size: 1.5rem;
  }
  
  .pdf-controls{
    flex-direction: column;
    padding: 1rem;
    gap: 1rem;
    justify-content: center;
    align-items: center;
    text-align: center;
  }
  
  .pdf-controls .left-group{
    flex-direction: row;
    gap: 1rem;
    align-items: center;
    justify-content: center;
    width: auto;
    margin: 0 auto;
  }
  
  .pdf-controls .right-group{
    width: auto;
    justify-content: center;
    margin: 0 auto;
  }
  
  .Pdf{
    height: 80vh;
  }
  
  .Files {
    grid-template-columns: 1fr;
  }
  
  .fs-inline-bar{
    position: fixed;
    bottom: 1.5rem;
    padding: 1rem 1.5rem;
    gap: 1rem;
    max-width: 96%;
  }
}

/* Large Mobile (551px - 767px) */
@media (max-width: 650px) {
  html {font-size: 58%}
  
  .Photo {
    width: calc(100% - 2.5rem);
    margin: 1.3rem auto;
    padding: 1rem;
  }
}

/* Mobile (320px - 550px) */
@media (max-width: 550px) {
  html {font-size: 56%}
  
  header {
    flex-direction: column;
    align-items: center;
  }
  
  .right-section {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
    width: 100%;
    margin-top: 2rem;
  }
  
  .right-section a {
    width: 100%;
    text-align: center;
    font-size: 200%;
  }
  
  .Photo {
    width: calc(100% - 2rem);
    margin: 1rem auto;
    border-width: 2px;
    border-radius: 1.5rem;
    padding: 0.8rem;
  }
  
  .Photo::before {
    inset: -2px;
    border-radius: 1.5rem;
    filter: blur(12px);
  }
  
  .Photo::after {
    border-radius: 1.5rem;
  }
  
  .Photo img {
    border-radius: 0.8rem;
  }
  
  .Data, .Folder-Data{
    margin: 1rem 0.5rem;
    padding: 1rem;
  }
  
  .pdf-header{
    padding: 1rem;
  }
  
  .pdf-tabs{
    gap: 0.6rem;
    flex-direction: column;
  }
  
  .pdf-tab{
    width: 100%;
    padding: 1rem 1.5rem;
    font-size: 1.4rem;
    text-align: center;
  }
  
  .pdf-controls{
    padding: 0.8rem;
    gap: 0.8rem;
    justify-content: center;
    align-items: center;
    text-align: center;
  }
  
  .pdf-controls .left-group{
    flex-direction: row;
    gap: 0.8rem;
    width: auto;
    justify-content: center;
    align-items: center;
    margin: 0 auto;
  }
  
  .pdf-controls .right-group{
    width: auto;
    justify-content: center;
    margin: 0 auto;
  }
  
  .pdf-controls .left-group button{
    flex: 0 0 auto;
  }
  
  .pdf-controls button{
    font-size: 1.4rem;
    padding: 0.8rem 1.2rem;
  }
  
  #pageIndicator{
    font-size: 1.4rem;
    padding: 0.8rem 1.2rem;
    order: 0;
  }
  
  .zoom-select select{
    min-width: 80px;
    font-size: 1.4rem;
  }
  
  .Pdf{
    height: 75vh;
    border-width: 2px;
  }
  
  .thumb-drawer{
    width: 280px;
  }
  
  .fs-inline-bar{
    position: fixed;
    bottom: 1rem;
    padding: 0.8rem 1rem;
    gap: 0.6rem;
    max-width: 98%;
    flex-direction: column;
  }
  
  .fs-inline-indicator{
    font-size: 1.3rem;
    padding: 0.6rem 1rem;
    width: 100%;
    text-align: center;
  }
  
  .fs-inline-btns{
    display: flex;
    gap: 0.5rem;
    flex-wrap: nowrap;
    justify-content: center;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
  
  .fs-inline-btn{
    font-size: 1.2rem;
    padding: 0.6rem 1rem;
    white-space: nowrap;
    flex-shrink: 0;
  }
  
  .fs-inline-zoom{
    min-width: 70px;
    font-size: 1.2rem;
    height: 32px;
    flex-shrink: 0;
  }
}

/* Small Mobile (376px - 450px) */
@media (max-width: 450px) {
  html {font-size: 54%}
  
  .Photo {
    width: calc(100% - 1.5rem);
    margin: 0.8rem auto;
    padding: 0.6rem;
  }
}

/* Extra Small Mobile (320px - 375px) */
@media (max-width: 375px) {
  html {font-size: 52%}
  
  .Photo {
    width: calc(100% - 1rem);
    margin: 0.6rem auto;
    border-radius: 1.2rem;
    padding: 0.6rem;
  }
  
  .Photo::before {
    border-radius: 1.2rem;
  }
  
  .Photo::after {
    border-radius: 1.2rem;
  }
  
  .Photo img {
    border-radius: 0.6rem;
  }
  
  .Data, .Folder-Data{
    margin: 0.8rem 0.3rem;
    padding: 0.8rem;
  }
  
  .thumb-drawer{
    width: 260px;
  }
}

/* ===== Performance Optimizations ===== */
.pdf-tab,.pdf-controls button,.Photo img{
  will-change:transform;
  backface-visibility:hidden;
}