v3
This commit is contained in:
parent
bd1a0b96c9
commit
018ea4ccf9
@ -17,5 +17,16 @@
|
|||||||
{% block content %}{% endblock %}
|
{% block content %}{% endblock %}
|
||||||
|
|
||||||
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0/dist/js/bootstrap.bundle.min.js"></script>
|
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0/dist/js/bootstrap.bundle.min.js"></script>
|
||||||
|
<script>
|
||||||
|
// Change navbar background on scroll
|
||||||
|
const nav = document.getElementById('main-nav');
|
||||||
|
window.addEventListener('scroll', () => {
|
||||||
|
if (window.scrollY >= 50) {
|
||||||
|
nav.classList.add('navbar-scrolled');
|
||||||
|
} else {
|
||||||
|
nav.classList.remove('navbar-scrolled');
|
||||||
|
}
|
||||||
|
});
|
||||||
|
</script>
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
||||||
|
|||||||
@ -7,8 +7,8 @@
|
|||||||
<div class="page-wrapper">
|
<div class="page-wrapper">
|
||||||
|
|
||||||
<!-- Navigation -->
|
<!-- Navigation -->
|
||||||
<nav class="navbar navbar-expand-lg navbar-dark fixed-top">
|
<nav class="navbar navbar-expand-lg navbar-dark fixed-top" id="main-nav">
|
||||||
<div class="container-fluid px-lg-5">
|
<div class="container-fluid">
|
||||||
<a class="navbar-brand" href="#">AmaFlix</a>
|
<a class="navbar-brand" href="#">AmaFlix</a>
|
||||||
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbarNav" aria-controls="navbarNav" aria-expanded="false" aria-label="Toggle navigation">
|
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbarNav" aria-controls="navbarNav" aria-expanded="false" aria-label="Toggle navigation">
|
||||||
<span class="navbar-toggler-icon"></span>
|
<span class="navbar-toggler-icon"></span>
|
||||||
@ -29,67 +29,63 @@
|
|||||||
|
|
||||||
<!-- Hero Section -->
|
<!-- Hero Section -->
|
||||||
{% if featured_movie %}
|
{% if featured_movie %}
|
||||||
<header class="hero-section" style="background-image: url('{{ featured_movie.thumbnail_url }}');">
|
<header class="hero-section">
|
||||||
<div class="hero-content-wrapper">
|
<div class="hero-backdrop" style="background-image: url('{{ featured_movie.thumbnail_url }}');"></div>
|
||||||
<div class="hero-content">
|
<div class="hero-content">
|
||||||
<h1 class="hero-title">{{ featured_movie.title }}</h1>
|
<h1 class="hero-title">{{ featured_movie.title }}</h1>
|
||||||
<p class="hero-description">{{ featured_movie.description|truncatewords:30 }}</p>
|
<p class="hero-description">{{ featured_movie.description|truncatewords:30 }}</p>
|
||||||
<div class="hero-buttons">
|
<div class="hero-buttons">
|
||||||
<a href="{{ featured_movie.video_url }}" target="_blank" class="btn btn-play"><i class="bi bi-play-fill"></i> Play</a>
|
<a href="{{ featured_movie.video_url }}" target="_blank" class="btn btn-play">
|
||||||
<a href="#" class="btn btn-more-info"><i class="bi bi-info-circle"></i> More Info</a>
|
<i class="bi bi-play-fill"></i> Play
|
||||||
</div>
|
</a>
|
||||||
|
<a href="#" class="btn btn-more-info">
|
||||||
|
<i class="bi bi-info-circle"></i> More Info
|
||||||
|
</a>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
<div class="hero-fade"></div>
|
||||||
</header>
|
</header>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
<!-- Movie Carousels -->
|
<!-- Movie Carousels -->
|
||||||
<main class="container-fluid movie-sections">
|
<main class="movie-sections">
|
||||||
<section class="movie-carousel-section">
|
<section class="movie-carousel-section">
|
||||||
<h2 class="section-title">Trending Now</h2>
|
<h2 class="section-title">Trending Now</h2>
|
||||||
<div class="movie-carousel-wrapper">
|
<div class="movie-carousel">
|
||||||
<div class="movie-carousel">
|
{% for movie in trending_movies %}
|
||||||
{% for movie in trending_movies %}
|
<div class="movie-card">
|
||||||
<div class="movie-card">
|
<img src="{{ movie.thumbnail_url }}" class="card-img-top" alt="{{ movie.title }}">
|
||||||
<img src="{{ movie.thumbnail_url }}" alt="{{ movie.title }}">
|
<div class="movie-card-body">
|
||||||
<div class="movie-card-overlay">
|
<h5 class="movie-card-title">{{ movie.title }}</h5>
|
||||||
<h5 class="movie-card-title">{{ movie.title }}</h5>
|
<p class="movie-card-text">Rating: {{ movie.rating }}</p>
|
||||||
<div class="movie-card-actions">
|
<a href="#" class="btn btn-sm btn-outline-light">Watch</a>
|
||||||
<a href="#" class="btn btn-sm btn-play-icon"><i class="bi bi-play-circle-fill"></i></a>
|
|
||||||
<span class="movie-rating">Rating: {{ movie.rating }}</span>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
{% endfor %}
|
|
||||||
</div>
|
</div>
|
||||||
|
{% endfor %}
|
||||||
</div>
|
</div>
|
||||||
</section>
|
</section>
|
||||||
|
|
||||||
<section class="movie-carousel-section">
|
<section class="movie-carousel-section">
|
||||||
<h2 class="section-title">Top Rated</h2>
|
<h2 class="section-title">Top Rated</h2>
|
||||||
<div class="movie-carousel-wrapper">
|
<div class="movie-carousel">
|
||||||
<div class="movie-carousel">
|
{% for movie in top_rated_movies %}
|
||||||
{% for movie in top_rated_movies %}
|
<div class="movie-card">
|
||||||
<div class="movie-card">
|
<img src="{{ movie.thumbnail_url }}" class="card-img-top" alt="{{ movie.title }}">
|
||||||
<img src="{{ movie.thumbnail_url }}" alt="{{ movie.title }}">
|
<div class="movie-card-body">
|
||||||
<div class="movie-card-overlay">
|
<h5 class="movie-card-title">{{ movie.title }}</h5>
|
||||||
<h5 class="movie-card-title">{{ movie.title }}</h5>
|
<p class="movie-card-text">Rating: {{ movie.rating }}</p>
|
||||||
<div class="movie-card-actions">
|
<a href="#" class="btn btn-sm btn-outline-light">Watch</a>
|
||||||
<a href="#" class="btn btn-sm btn-play-icon"><i class="bi bi-play-circle-fill"></i></a>
|
|
||||||
<span class="movie-rating">Rating: {{ movie.rating }}</span>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
{% endfor %}
|
|
||||||
</div>
|
</div>
|
||||||
|
{% endfor %}
|
||||||
</div>
|
</div>
|
||||||
</section>
|
</section>
|
||||||
</main>
|
</main>
|
||||||
|
|
||||||
<!-- Footer -->
|
<!-- Footer -->
|
||||||
<footer class="main-footer mt-5 py-4 text-center">
|
<footer class="main-footer mt-5 py-4 text-center text-muted">
|
||||||
<p class="mb-0">AmaFlix © 2025. All Rights Reserved.</p>
|
<p class="mb-0">AmaFlix © 2025</p>
|
||||||
</footer>
|
</footer>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
|||||||
@ -1,109 +1,136 @@
|
|||||||
@import url('https://cdn.jsdelivr.net/npm/bootstrap-icons@1.11.3/font/bootstrap-icons.min.css');
|
@import url('https://cdn.jsdelivr.net/npm/bootstrap-icons@1.11.3/font/bootstrap-icons.min.css');
|
||||||
|
|
||||||
|
:root {
|
||||||
|
--netflix-black: #141414;
|
||||||
|
--netflix-red: #E50914;
|
||||||
|
--primary-text: #FFFFFF;
|
||||||
|
--secondary-text: #A9A9A9;
|
||||||
|
--card-hover-border: #fff;
|
||||||
|
}
|
||||||
|
|
||||||
body {
|
body {
|
||||||
background-color: #141414;
|
background-color: var(--netflix-black);
|
||||||
color: #fff;
|
color: var(--primary-text);
|
||||||
font-family: 'Roboto', sans-serif;
|
font-family: 'Roboto', sans-serif;
|
||||||
}
|
}
|
||||||
|
|
||||||
h1, h2, h3, h4, h5, h6 {
|
|
||||||
font-family: 'Bebas Neue', sans-serif;
|
|
||||||
color: #fff;
|
|
||||||
}
|
|
||||||
|
|
||||||
.page-wrapper {
|
.page-wrapper {
|
||||||
background-color: #141414;
|
background-color: var(--netflix-black);
|
||||||
min-height: 100vh;
|
min-height: 100vh;
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
|
overflow-x: hidden;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* --- Navigation --- */
|
/* --- Navigation --- */
|
||||||
.navbar {
|
#main-nav {
|
||||||
background-color: rgba(20, 20, 20, 0.8);
|
background-color: transparent;
|
||||||
backdrop-filter: blur(10px);
|
transition: background-color 0.4s ease-out;
|
||||||
transition: background-color 0.3s ease;
|
padding-top: 10px;
|
||||||
|
padding-bottom: 10px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.navbar.scrolled {
|
#main-nav.navbar-scrolled {
|
||||||
background-color: #141414;
|
background-color: #0c0c0c;
|
||||||
}
|
}
|
||||||
|
|
||||||
.navbar-brand {
|
.navbar-brand {
|
||||||
font-family: 'Bebas Neue', sans-serif;
|
font-family: 'Bebas Neue', sans-serif;
|
||||||
color: #E50914 !important;
|
color: var(--netflix-red) !important;
|
||||||
font-size: 2.5rem;
|
font-size: 2.5rem;
|
||||||
letter-spacing: 1px;
|
letter-spacing: 1px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.nav-link {
|
.nav-link {
|
||||||
color: #a9a9a9 !important;
|
color: var(--secondary-text) !important;
|
||||||
font-weight: 500;
|
font-weight: 500;
|
||||||
transition: color 0.2s ease;
|
transition: color 0.2s ease;
|
||||||
}
|
}
|
||||||
|
|
||||||
.nav-link:hover, .nav-link.active {
|
.nav-link:hover, .nav-link.active {
|
||||||
color: #fff !important;
|
color: var(--primary-text) !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* --- Hero Section --- */
|
/* --- Hero Section --- */
|
||||||
.hero-section {
|
.hero-section {
|
||||||
position: relative;
|
position: relative;
|
||||||
height: 90vh;
|
height: 95vh;
|
||||||
background-size: cover;
|
|
||||||
background-position: center top;
|
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
|
padding: 0 4%;
|
||||||
}
|
}
|
||||||
|
|
||||||
.hero-section::after {
|
.hero-backdrop {
|
||||||
|
position: absolute;
|
||||||
|
top: 0;
|
||||||
|
left: 0;
|
||||||
|
right: 0;
|
||||||
|
bottom: 0;
|
||||||
|
background-size: cover;
|
||||||
|
background-position: center 20%;
|
||||||
|
opacity: 0.6;
|
||||||
|
}
|
||||||
|
|
||||||
|
.hero-section::before {
|
||||||
content: '';
|
content: '';
|
||||||
position: absolute;
|
position: absolute;
|
||||||
top: 0;
|
top: 0;
|
||||||
left: 0;
|
left: 0;
|
||||||
right: 0;
|
right: 0;
|
||||||
bottom: 0;
|
bottom: 0;
|
||||||
background: linear-gradient(to top, #141414 15%, rgba(20, 20, 20, 0) 50%), linear-gradient(to right, rgba(20, 20, 20, 0.5) 0%, rgba(20, 20, 20, 0) 30%);
|
background: linear-gradient(to right, rgba(20, 20, 20, 0.8) 0%, rgba(20, 20, 20, 0) 50%);
|
||||||
}
|
}
|
||||||
|
|
||||||
.hero-content-wrapper {
|
.hero-fade {
|
||||||
position: relative;
|
position: absolute;
|
||||||
z-index: 1;
|
bottom: 0;
|
||||||
padding: 0 5%;
|
left: 0;
|
||||||
|
right: 0;
|
||||||
|
height: 15vh;
|
||||||
|
background: linear-gradient(to top, var(--netflix-black) 20%, transparent 100%);
|
||||||
}
|
}
|
||||||
|
|
||||||
.hero-content {
|
.hero-content {
|
||||||
max-width: 550px;
|
position: relative;
|
||||||
|
z-index: 2;
|
||||||
|
max-width: 40vw;
|
||||||
}
|
}
|
||||||
|
|
||||||
.hero-title {
|
.hero-title {
|
||||||
font-size: 5rem;
|
font-family: 'Bebas Neue', sans-serif;
|
||||||
|
font-size: clamp(3rem, 6vw, 6rem);
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
text-shadow: 2px 2px 8px rgba(0,0,0,0.7);
|
text-shadow: 0 0 30px rgba(0,0,0,0.8);
|
||||||
}
|
}
|
||||||
|
|
||||||
.hero-description {
|
.hero-description {
|
||||||
font-size: 1.2rem;
|
font-size: clamp(1rem, 1.5vw, 1.2rem);
|
||||||
line-height: 1.5;
|
line-height: 1.6;
|
||||||
margin: 1rem 0 2rem;
|
margin: 1.5rem 0 2.5rem;
|
||||||
text-shadow: 1px 1px 4px rgba(0,0,0,0.7);
|
text-shadow: 0 0 20px rgba(0,0,0,0.8);
|
||||||
|
max-width: 600px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.hero-buttons .btn {
|
.hero-buttons .btn {
|
||||||
margin-right: 1rem;
|
margin-right: 1rem;
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
padding: 0.75rem 2rem;
|
padding: 0.8rem 2.2rem;
|
||||||
border-radius: 5px;
|
border-radius: 5px;
|
||||||
font-size: 1.1rem;
|
font-size: 1.1rem;
|
||||||
display: inline-flex;
|
display: inline-flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
gap: 0.5rem;
|
gap: 0.7rem;
|
||||||
|
border: none;
|
||||||
|
transition: transform 0.2s ease;
|
||||||
|
}
|
||||||
|
|
||||||
|
.hero-buttons .btn:hover {
|
||||||
|
transform: scale(1.05);
|
||||||
}
|
}
|
||||||
|
|
||||||
.btn-play {
|
.btn-play {
|
||||||
background-color: #fff;
|
background-color: var(--primary-text);
|
||||||
color: #000;
|
color: #000;
|
||||||
border: none;
|
|
||||||
}
|
}
|
||||||
.btn-play:hover {
|
.btn-play:hover {
|
||||||
background-color: rgba(255, 255, 255, 0.8);
|
background-color: rgba(255, 255, 255, 0.8);
|
||||||
@ -111,8 +138,7 @@ h1, h2, h3, h4, h5, h6 {
|
|||||||
|
|
||||||
.btn-more-info {
|
.btn-more-info {
|
||||||
background-color: rgba(109, 109, 110, 0.7);
|
background-color: rgba(109, 109, 110, 0.7);
|
||||||
color: #fff;
|
color: var(--primary-text);
|
||||||
border: none;
|
|
||||||
}
|
}
|
||||||
.btn-more-info:hover {
|
.btn-more-info:hover {
|
||||||
background-color: rgba(109, 109, 110, 0.5);
|
background-color: rgba(109, 109, 110, 0.5);
|
||||||
@ -120,27 +146,25 @@ h1, h2, h3, h4, h5, h6 {
|
|||||||
|
|
||||||
/* --- Movie Carousels --- */
|
/* --- Movie Carousels --- */
|
||||||
.movie-sections {
|
.movie-sections {
|
||||||
margin-top: -10vh; /* Pulls the carousels up into the hero gradient */
|
margin-top: -10vh; /* Overlap with hero section */
|
||||||
position: relative;
|
position: relative;
|
||||||
z-index: 2;
|
z-index: 10;
|
||||||
|
padding: 0 4%;
|
||||||
}
|
}
|
||||||
|
|
||||||
.section-title {
|
.section-title {
|
||||||
font-size: 1.8rem;
|
font-family: 'Bebas Neue', sans-serif;
|
||||||
|
font-size: 2rem;
|
||||||
font-weight: 500;
|
font-weight: 500;
|
||||||
margin-bottom: 1rem;
|
margin-bottom: 1.2rem;
|
||||||
padding: 0 5%;
|
|
||||||
}
|
|
||||||
|
|
||||||
.movie-carousel-wrapper {
|
|
||||||
position: relative;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.movie-carousel {
|
.movie-carousel {
|
||||||
display: flex;
|
display: flex;
|
||||||
overflow-x: scroll;
|
gap: 10px;
|
||||||
|
padding-bottom: 2rem;
|
||||||
|
overflow-x: auto;
|
||||||
overflow-y: hidden;
|
overflow-y: hidden;
|
||||||
padding: 0 5% 20px;
|
|
||||||
scrollbar-width: none; /* Firefox */
|
scrollbar-width: none; /* Firefox */
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -149,44 +173,45 @@ h1, h2, h3, h4, h5, h6 {
|
|||||||
}
|
}
|
||||||
|
|
||||||
.movie-card {
|
.movie-card {
|
||||||
flex: 0 0 auto;
|
flex: 0 0 18%;
|
||||||
width: 16vw; /* Responsive width */
|
|
||||||
max-width: 280px;
|
max-width: 280px;
|
||||||
min-width: 180px;
|
min-width: 200px;
|
||||||
margin-right: 10px;
|
background-color: #181818;
|
||||||
border-radius: 5px;
|
border-radius: 5px;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
position: relative;
|
position: relative;
|
||||||
transition: transform 0.3s ease, box-shadow 0.3s ease;
|
transition: all 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
background-color: #181818;
|
border: 2px solid transparent;
|
||||||
}
|
}
|
||||||
|
|
||||||
.movie-card img {
|
.movie-card .card-img-top {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
height: 100%;
|
height: auto;
|
||||||
|
aspect-ratio: 16/9;
|
||||||
object-fit: cover;
|
object-fit: cover;
|
||||||
display: block;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.movie-card-overlay {
|
.movie-card-body {
|
||||||
|
padding: 1rem;
|
||||||
|
opacity: 0;
|
||||||
position: absolute;
|
position: absolute;
|
||||||
bottom: 0;
|
bottom: 0;
|
||||||
left: 0;
|
left: 0;
|
||||||
right: 0;
|
right: 0;
|
||||||
background: linear-gradient(to top, rgba(0,0,0,0.9) 0%, rgba(0,0,0,0) 100%);
|
background: linear-gradient(to top, #181818 50%, transparent);
|
||||||
padding: 2rem 1rem 1rem;
|
transition: opacity 0.4s ease;
|
||||||
opacity: 0;
|
|
||||||
transition: opacity 0.3s ease;
|
|
||||||
}
|
|
||||||
|
|
||||||
.movie-card:hover .movie-card-overlay {
|
|
||||||
opacity: 1;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.movie-card:hover {
|
.movie-card:hover {
|
||||||
transform: scale(1.05);
|
transform: scale(1.15) translateY(-10px);
|
||||||
box-shadow: 0 10px 20px rgba(0, 0, 0, 0.5);
|
z-index: 20;
|
||||||
|
border-color: var(--card-hover-border);
|
||||||
|
box-shadow: 0 15px 25px rgba(0,0,0,0.7);
|
||||||
|
}
|
||||||
|
|
||||||
|
.movie-card:hover .movie-card-body {
|
||||||
|
opacity: 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
.movie-card-title {
|
.movie-card-title {
|
||||||
@ -196,28 +221,38 @@ h1, h2, h3, h4, h5, h6 {
|
|||||||
margin-bottom: 0.5rem;
|
margin-bottom: 0.5rem;
|
||||||
}
|
}
|
||||||
|
|
||||||
.movie-card-actions {
|
.movie-card-text {
|
||||||
display: flex;
|
|
||||||
justify-content: space-between;
|
|
||||||
align-items: center;
|
|
||||||
}
|
|
||||||
|
|
||||||
.btn-play-icon {
|
|
||||||
color: #fff;
|
|
||||||
font-size: 2rem;
|
|
||||||
}
|
|
||||||
.btn-play-icon:hover {
|
|
||||||
color: #E50914;
|
|
||||||
}
|
|
||||||
|
|
||||||
.movie-rating {
|
|
||||||
font-size: 0.8rem;
|
font-size: 0.8rem;
|
||||||
color: #a9a9a9;
|
color: var(--secondary-text);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* --- Footer --- */
|
/* --- Footer --- */
|
||||||
.main-footer {
|
.main-footer {
|
||||||
background-color: #181818;
|
border-top: 1px solid #222;
|
||||||
color: #a9a9a9;
|
|
||||||
font-size: 0.9rem;
|
font-size: 0.9rem;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* Responsive */
|
||||||
|
@media (max-width: 992px) {
|
||||||
|
.hero-content {
|
||||||
|
max-width: 60vw;
|
||||||
|
}
|
||||||
|
.movie-card {
|
||||||
|
flex-basis: 22%;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@media (max-width: 768px) {
|
||||||
|
.hero-content {
|
||||||
|
max-width: 80vw;
|
||||||
|
}
|
||||||
|
.hero-description {
|
||||||
|
display: -webkit-box;
|
||||||
|
-webkit-line-clamp: 3;
|
||||||
|
-webkit-box-orient: vertical;
|
||||||
|
overflow: hidden;
|
||||||
|
}
|
||||||
|
.movie-card {
|
||||||
|
flex-basis: 30%;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user