Skip to content

Commit

Permalink
Add a separate file for realistic shadows
Browse files Browse the repository at this point in the history
  • Loading branch information
aadhithbala committed Jul 22, 2023
1 parent c9e9b9c commit 4b24a00
Show file tree
Hide file tree
Showing 6 changed files with 27 additions and 4 deletions.
2 changes: 1 addition & 1 deletion assets/icons/bullhorn.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion assets/icons/donate.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion assets/icons/foster.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion assets/icons/volunteer.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>The Cat Lounge</title>
<link rel="stylesheet" href="styles.css" />
<link rel="stylesheet" href="shadow.css" />
<script src="script.js" defer></script>
</head>
<body>
Expand Down
22 changes: 22 additions & 0 deletions shadow.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
:root {
--shadow-color: 145deg 33% 52%;
--shadow-elevation-low: 0.3px 0.5px 0.7px hsl(var(--shadow-color) / 0.34),
0.4px 0.8px 1px -1.2px hsl(var(--shadow-color) / 0.35),
1px 2px 2.5px -2.4px hsl(var(--shadow-color) / 0.35);
--shadow-elevation-medium: 0.3px 0.5px 0.7px hsl(var(--shadow-color) / 0.36),
0.8px 1.7px 2.1px -0.8px hsl(var(--shadow-color) / 0.36),
2.1px 4.2px 5.3px -1.6px hsl(var(--shadow-color) / 0.37),
5.1px 10.1px 12.8px -2.4px hsl(var(--shadow-color) / 0.37);
--shadow-elevation-high: 0.3px 0.5px 0.7px hsl(var(--shadow-color) / 0.34),
1.5px 3px 3.8px -0.4px hsl(var(--shadow-color) / 0.34),
2.8px 5.6px 7.1px -0.7px hsl(var(--shadow-color) / 0.34),
4.6px 9.2px 11.6px -1px hsl(var(--shadow-color) / 0.34),
7.3px 14.7px 18.6px -1.4px hsl(var(--shadow-color) / 0.34),
11.4px 22.8px 28.9px -1.8px hsl(var(--shadow-color) / 0.34),
17.3px 34.7px 43.9px -2.1px hsl(var(--shadow-color) / 0.35),
25.5px 51px 64.6px -2.4px hsl(var(--shadow-color) / 0.35);
}

.card-box {
box-shadow: var(--shadow-elevation-medium);
}

0 comments on commit 4b24a00

Please sign in to comment.